Fixes a crash. Thanks, Richard.
llvm-svn: 173701
return 0;
if (!LangOpts.CPlusPlus && !LangOpts.C99) {
- Diag(SlashLoc, diag::warn_ucn_not_valid_in_c89);
+ if (Result && !isLexingRawMode())
+ Diag(SlashLoc, diag::warn_ucn_not_valid_in_c89);
return 0;
}
}
#define MY_UCN \u00FC // expected-warning {{universal character names are only valid in C99 or C++; treating as '\' followed by identifier}}
+#define NOT_A_UCN \h // no-warning
+
+extern int idWithUCN\u00FC; // expected-warning {{universal character names are only valid in C99 or C++; treating as '\' followed by identifier}} expected-error {{expected ';'}}