summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Lex/Pragma.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Lex/Pragma.cpp b/clang/lib/Lex/Pragma.cpp
index 51da2baac9e..99d56182c1b 100644
--- a/clang/lib/Lex/Pragma.cpp
+++ b/clang/lib/Lex/Pragma.cpp
@@ -1307,7 +1307,7 @@ static bool LexModuleName(
&ModuleName) {
while (true) {
PP.LexUnexpandedToken(Tok);
- if (Tok.isNot(tok::identifier)) {
+ if (Tok.isAnnotation() || !Tok.getIdentifierInfo()) {
PP.Diag(Tok.getLocation(), diag::err_pp_expected_module_name)
<< ModuleName.empty();
return true;
OpenPOWER on IntegriCloud