Don't skip past the '}' if an expression has error and is not followed by ';'.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99972 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Parser/statements.c b/test/Parser/statements.c
index a662c9b..bc7192a 100644
--- a/test/Parser/statements.c
+++ b/test/Parser/statements.c
@@ -57,3 +57,8 @@
int test7() {
return 4 // expected-error {{expected ';' after return statement}}
}
+
+void test8() {
+ // Should not skip '}' and produce a "expected '}'" error.
+ undecl // expected-error {{use of undeclared identifier 'undecl'}}
+}