diff options
author | Douglas Gregor <dgregor@apple.com> | 2012-05-01 01:53:49 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2012-05-01 01:53:49 +0000 |
commit | 6d3b93d631640125f912339df19b0d2a15af5c9b (patch) | |
tree | 6cb4382efb097d995c67564f6f731bf5dfa235e2 /test/Sema/compare.c | |
parent | c30636a160c640f32f847637004a2632b88cad6c (diff) | |
download | clang-6d3b93d631640125f912339df19b0d2a15af5c9b.tar.gz |
Turn the mixed-sign-comparison diagnostic into a runtime behavior
diagnostic, from Eitan Adler!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155876 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Sema/compare.c')
-rw-r--r-- | test/Sema/compare.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/Sema/compare.c b/test/Sema/compare.c index 03aebb3a04..406ade81aa 100644 --- a/test/Sema/compare.c +++ b/test/Sema/compare.c @@ -333,3 +333,10 @@ struct test11S { unsigned x : 30; }; int test11(unsigned y, struct test11S *p) { return y > (p->x >> 24); // no-warning } + +typedef char one_char[1]; +typedef char two_chars[2]; + +void test12(unsigned a) { + if (0 && -1 > a) { } +} |