diff options
Diffstat (limited to 'test/SemaCXX/enum.cpp')
-rw-r--r-- | test/SemaCXX/enum.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/test/SemaCXX/enum.cpp b/test/SemaCXX/enum.cpp index 9668c84693d3..db256812ab80 100644 --- a/test/SemaCXX/enum.cpp +++ b/test/SemaCXX/enum.cpp @@ -14,14 +14,13 @@ void f() { // <rdar://problem/6502934> typedef enum Foo { - A = 0, - B = 1 + A = 0, + B = 1 } Foo; - - + void bar() { - Foo myvar = A; - myvar = B; + Foo myvar = A; + myvar = B; } /// PR3688 @@ -32,7 +31,7 @@ struct s1 { enum e1 { YES, NO }; static enum e1 badfunc(struct s1 *q) { - return q->bar(); // expected-error{{return type of called function ('enum s1::e1') is incomplete}} + return q->bar(); // expected-error{{calling function with incomplete return type 'enum s1::e1'}} } enum e2; // expected-error{{ISO C++ forbids forward references to 'enum' types}} |