[clang] [clang-tools-extra] [clang] Make `InitListExpr::isExplicit()` work (PR #195175)
via cfe-commits
cfe-commits at lists.llvm.org
Mon May 4 09:28:27 PDT 2026
================
@@ -8444,8 +8447,10 @@ ExprResult InitializationSequence::Perform(Sema &S,
case SK_RewrapInitList: {
Expr *E = CurInit.get();
InitListExpr *Syntactic = Step->WrappingSyntacticList;
- InitListExpr *ILE = new (S.Context) InitListExpr(S.Context,
- Syntactic->getLBraceLoc(), E, Syntactic->getRBraceLoc());
+ assert(Syntactic->isExplicit());
----------------
Sirraide wrote:
It probably doesn’t hurt to do this defensively here yeah (i.e. copy the `IsExplicit` state)
https://github.com/llvm/llvm-project/pull/195175
More information about the cfe-commits
mailing list