================
@@ -2034,12 +2034,14 @@ void Preprocessor::ExpandBuiltinMacro(Token &Tok) {
     }
 
     // Discard the ')', preserving 'Tok' as our result.
-    Token RParen;
-    LexNonComment(RParen);
-    if (RParen.isNot(tok::r_paren)) {
+    Token Next;
+    LexNonComment(Next);
+    if (Next.isNot(tok::r_paren)) {
       Diag(getLocForEndOfToken(Tok.getLocation()), diag::err_pp_expected_after)
         << Tok.getKind() << tok::r_paren;
       Diag(LParenLoc, diag::note_matching) << tok::l_paren;
+      if (Next.isOneOf(tok::eof, tok::eod) || Next.isAnnotation())
----------------
shafik wrote:

If the `|| Next.isAnnotation()`  case tested below? If not it should be.

https://github.com/llvm/llvm-project/pull/229156
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to