PR10392: "#pragma GCC visibility" must not expand macros in its
arguments.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135552 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Parse/ParsePragma.cpp b/lib/Parse/ParsePragma.cpp
index c30ab75..445a724 100644
--- a/lib/Parse/ParsePragma.cpp
+++ b/lib/Parse/ParsePragma.cpp
@@ -38,7 +38,7 @@
   SourceLocation VisLoc = VisTok.getLocation();
 
   Token Tok;
-  PP.Lex(Tok);
+  PP.LexUnexpandedToken(Tok);
 
   const IdentifierInfo *PushPop = Tok.getIdentifierInfo();
 
@@ -49,20 +49,20 @@
     VisType = 0;
   } else if (PushPop && PushPop->isStr("push")) {
     IsPush = true;
-    PP.Lex(Tok);
+    PP.LexUnexpandedToken(Tok);
     if (Tok.isNot(tok::l_paren)) {
       PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_lparen)
         << "visibility";
       return;
     }
-    PP.Lex(Tok);
+    PP.LexUnexpandedToken(Tok);
     VisType = Tok.getIdentifierInfo();
     if (!VisType) {
       PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier)
         << "visibility";
       return;
     }
-    PP.Lex(Tok);
+    PP.LexUnexpandedToken(Tok);
     if (Tok.isNot(tok::r_paren)) {
       PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_rparen)
         << "visibility";
@@ -73,7 +73,7 @@
       << "visibility";
     return;
   }
-  PP.Lex(Tok);
+  PP.LexUnexpandedToken(Tok);
   if (Tok.isNot(tok::eod)) {
     PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol)
       << "visibility";