hoist checks for ; and in out of ParseInitDeclaratorListAfterFirstDeclarator
into ParseSimpleDeclaration, and improve a diagnostic.
llvm-svn: 68009
diff --git a/clang/test/Parser/typeof.c b/clang/test/Parser/typeof.c
index 8cb16c3..76e8d47 100644
--- a/clang/test/Parser/typeof.c
+++ b/clang/test/Parser/typeof.c
@@ -9,8 +9,8 @@
short typeof (int) aShortInt; // expected-error{{'short typeof' is invalid}}
int int ttt; // expected-error{{cannot combine with previous 'int' declaration specifier}}
typeof(TInt) anInt;
- short TInt eee; // expected-error{{parse error}}
- void ary[7] fff; // expected-error{{array has incomplete element type 'void'}} expected-error{{parse error}}
+ short TInt eee; // expected-error{{expected ';' at end of declaration}}
+ void ary[7] fff; // expected-error{{array has incomplete element type 'void'}} expected-error{{expected ';' at end of declaration}}
typeof(void ary[7]) anIntError; // expected-error{{expected ')'}} expected-note {{to match this '('}} expected-warning {{type specifier missing, defaults to 'int'}}
typeof(const int) aci;
const typeof (*pi) aConstInt;
diff --git a/clang/test/Sema/init.c b/clang/test/Sema/init.c
index 9430f31..cbf75e1 100644
--- a/clang/test/Sema/init.c
+++ b/clang/test/Sema/init.c
@@ -20,7 +20,7 @@
int test() {
int a[10];
int b[10] = a; // expected-error {{initialization with '{...}' expected}}
-int +; // expected-error {{expected identifier or '('}} expected-error {{parse error}}
+int +; // expected-error {{expected identifier or '('}} expected-error {{expected ';' at end of declaration}}
}