Avoid extra error messages if method definition is inside function.
llvm-svn: 196757
diff --git a/clang/test/Parser/cxx-class.cpp b/clang/test/Parser/cxx-class.cpp
index 5fac797..d4d8c44 100644
--- a/clang/test/Parser/cxx-class.cpp
+++ b/clang/test/Parser/cxx-class.cpp
@@ -113,6 +113,16 @@
}
}
+class pr16989 {
+ void tpl_mem(int *) {
+ return;
+ class C2 {
+ void f();
+ };
+ void C2::f() {} // expected-error{{function definition is not allowed here}}
+ };
+};
+
// PR11109 must appear at the end of the source file
class pr11109r3 { // expected-note{{to match this '{'}}
public // expected-error{{expected ':'}} expected-error{{expected '}'}} expected-error{{expected ';' after class}}