my previous patch caused sema to drop the global qualifier, make
sure to pass it down.  This makes the code a bit gross, I will clean
it up in subsequent commits.





git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@61650 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Parse/Parser.cpp b/lib/Parse/Parser.cpp
index 381c84e..29843b1 100644
--- a/lib/Parse/Parser.cpp
+++ b/lib/Parse/Parser.cpp
@@ -741,14 +741,16 @@
 /// will not be called twice, once to check whether we have a declaration
 /// specifier, and another one to get the actual type inside
 /// ParseDeclarationSpecifiers).
-void Parser::TryAnnotateTypeOrScopeToken() {
+///
+/// This returns true if the token was annotated.
+bool Parser::TryAnnotateTypeOrScopeToken(const Token *GlobalQualifier) {
   // FIXME: what about template-ids?
   if (Tok.is(tok::annot_qualtypename) || Tok.is(tok::annot_cxxscope))
-    return;
+    return false;
 
   CXXScopeSpec SS;
   if (getLang().CPlusPlus)
-    MaybeParseCXXScopeSpecifier(SS);
+    MaybeParseCXXScopeSpecifier(SS, GlobalQualifier);
 
   if (Tok.is(tok::identifier)) {
     DeclTy *Template = 0;
@@ -772,7 +774,7 @@
         // In case the tokens were cached, have Preprocessor replace
         // them with the annotation token.
         PP.AnnotateCachedTokens(Tok);
-        return;
+        return true;
       }
     }
 
@@ -785,7 +787,7 @@
   // names a type.
 
   if (SS.isEmpty())
-    return;
+    return false;
   
   // A C++ scope specifier that isn't followed by a typename.
   // Push the current token back into the token stream (or revert it if it is
@@ -801,6 +803,7 @@
   // In case the tokens were cached, have Preprocessor replace them with the
   // annotation token.
   PP.AnnotateCachedTokens(Tok);
+  return true;
 }
 
 /// TryAnnotateScopeToken - Like TryAnnotateTypeOrScopeToken but only