Fix new check for missing semicolon after struct definition to deal with the
case where the type in the following declaration is specified as a template-id,
and refactor for clarity.
llvm-svn: 195280
diff --git a/clang/test/Parser/recovery.cpp b/clang/test/Parser/recovery.cpp
index b5b0948..60b4b5a 100644
--- a/clang/test/Parser/recovery.cpp
+++ b/clang/test/Parser/recovery.cpp
@@ -119,3 +119,13 @@
struct Inner4 {} // ok, no missing ';' here
Inner5;
}
+
+namespace NS {
+ template<typename T> struct Foo {};
+}
+struct MissingSemiThenTemplate1 {} // expected-error {{expected ';' after struct}}
+NS::Foo<int> missingSemiBeforeFunctionReturningTemplateId1();
+
+using NS::Foo;
+struct MissingSemiThenTemplate2 {} // expected-error {{expected ';' after struct}}
+Foo<int> missingSemiBeforeFunctionReturningTemplateId2();