diff options
author | John McCall <rjmccall@apple.com> | 2009-11-05 00:40:04 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2009-11-05 00:40:04 +0000 |
commit | 45aa4557fe4210034e85f4a807ff637a9dd146d6 (patch) | |
tree | 81fd182a940311d6dbca51680d07a9464da0e663 /test/Parser | |
parent | b1c2ea5dddc9188e2ea30de7f6546f640b85dead (diff) |
Implement -Wsign-compare, or at least the actual comparison part of it.
Conditional operands are next.
Fixes part of rdar://problem/7289584.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86083 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Parser')
-rw-r--r-- | test/Parser/if-scope-c90.c | 2 | ||||
-rw-r--r-- | test/Parser/if-scope-c99.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/test/Parser/if-scope-c90.c b/test/Parser/if-scope-c90.c index fdc75e9f10..53987dccbc 100644 --- a/test/Parser/if-scope-c90.c +++ b/test/Parser/if-scope-c90.c @@ -2,7 +2,7 @@ int f (int z) { - if (z > sizeof (enum {a, b})) + if (z > (int) sizeof (enum {a, b})) return a; return b; } diff --git a/test/Parser/if-scope-c99.c b/test/Parser/if-scope-c99.c index 37cd0e15ab..b4cb51ca8c 100644 --- a/test/Parser/if-scope-c99.c +++ b/test/Parser/if-scope-c99.c @@ -2,7 +2,7 @@ int f (int z) { - if (z > sizeof (enum {a, b})) + if (z > (int) sizeof (enum {a, b})) return a; return b; // expected-error{{use of undeclared identifier}} } |