Patch from Brian Brooks <brooks.brian@gmail.com>!
llvm-svn: 166893
}
if (Tok.is(tok::equal)) {
+ if (Ident == 0) {
+ Diag(Tok, diag::err_expected_ident);
+ // Skip to end of the definition and eat the ';'.
+ SkipUntil(tok::semi);
+ return 0;
+ }
if (!attrs.empty())
Diag(attrTok, diag::err_unexpected_namespace_attributes_alias);
if (InlineLoc.isValid())
void foo() {
namespace a { typedef g::o o; } // expected-error{{namespaces can only be defined in global or namespace scope}}
}
+
+// PR14085
+namespace PR14085 {}
+namespace = PR14085; // expected-error {{expected identifier}}