================ @@ -3705,6 +3713,12 @@ bool Parser::ParseExpressionList(SmallVectorImpl<Expr *> &Exprs, Token Comma = Tok; ConsumeToken(); checkPotentialAngleBracketDelimiter(Comma); + + if (Tok.is(tok::r_paren)) { + if (HasTrailingComma) + *HasTrailingComma = true; + break; + } ---------------- a-tarasyuk wrote:
@zyn0217 To handle a trailing comma, the previous token has to be a comma, and the next one a `r_paren`. https://github.com/llvm/llvm-project/blob/46f43b6d92e49b80df13e8a537a95767ffbaac9f/clang/lib/Parse/ParseExpr.cpp#L3702-L3707 https://github.com/llvm/llvm-project/pull/114684 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits