[clang] [Clang] Fix mangling of parenthesized aggregate initialization (PR #232357)
Kunal Dubey via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 15 23:08:43 PDT 2026
================
@@ -5770,7 +5773,17 @@ void CXXNameMangler::mangleExpression(const Expr *E, unsigned Arity,
Sub = CCE->getArg(0)->IgnoreImplicit();
if (auto *StdInitList = dyn_cast<CXXStdInitializerListExpr>(Sub))
Sub = StdInitList->getSubExpr()->IgnoreImplicit();
- if (auto *IL = dyn_cast<InitListExpr>(Sub)) {
+ if (auto *PLIE = dyn_cast<CXXParenListInitExpr>(Sub)) {
----------------
xakep8 wrote:
Good catch. I moved the single-operand parenthesized-initializer handling into the common cast-mangling path and added tests for both the C-style and static_cast forms. Their manglings also match GCC: https://godbolt.org/z/xWPcnr3K6
https://github.com/llvm/llvm-project/pull/232357
More information about the cfe-commits
mailing list