diff options
author | Chris Lattner <sabre@nondot.org> | 2009-02-28 19:37:57 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-02-28 19:37:57 +0000 |
commit | 309e48695b9533db3c6e37e15dd4ebc57a0dd351 (patch) | |
tree | d9fbb3ffea4b3a0643c91bbfd6e080cb7541a637 /clang/test/Parser/control-scope.c | |
parent | d4ed7e8bb9fae939e2bf127af7e2e0b50aacbb36 (diff) | |
download | bcm5719-llvm-309e48695b9533db3c6e37e15dd4ebc57a0dd351.tar.gz bcm5719-llvm-309e48695b9533db3c6e37e15dd4ebc57a0dd351.zip |
Fix a crash in test/Parser/control-scope.c that testrunner didn't
notice because it was a negative test with a fix suggested by
Jean-Daniel Dupas. Convert the test from a negative to a positive
test to catch stuff like this.
llvm-svn: 65708
Diffstat (limited to 'clang/test/Parser/control-scope.c')
-rw-r--r-- | clang/test/Parser/control-scope.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/test/Parser/control-scope.c b/clang/test/Parser/control-scope.c index 3d588d63b4c..4beed7eecd3 100644 --- a/clang/test/Parser/control-scope.c +++ b/clang/test/Parser/control-scope.c @@ -1,8 +1,8 @@ -// RUN: not clang %s -std=c90 && +// RUN: clang %s -std=c90 -verify && // RUN: clang %s -std=c99 int f (int z) { - if (z + sizeof (enum {a})) - return 1 + sizeof (enum {a}); + if (z + sizeof (enum {a})) // expected-note {{previous definition is here}} + return 1 + sizeof (enum {a}); // expected-error {{redefinition of enumerator 'a'}} return 0; } |