[clang] [clang][Sema] Fix rejection of non-dependent void{} during template instantiation (PR #228340)

Oliver Hunt via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 12 23:15:36 PST 2026


================
@@ -1870,12 +1870,19 @@ class CXXFunctionalCastExpr final
   static CXXFunctionalCastExpr *
   CreateEmpty(const ASTContext &Context, unsigned PathSize, bool HasFPFeatures);
 
+  static CXXFunctionalCastExpr *
+  CreateListInitializer(const ASTContext &Context, QualType T, ExprValueKind VK,
+                        TypeSourceInfo *Written, CastKind Kind, Expr *Op,
+                        const CXXCastPath *Path, FPOptionsOverride FPO,
+                        SourceLocation R);
+
   SourceLocation getLParenLoc() const { return LParenLoc; }
   void setLParenLoc(SourceLocation L) { LParenLoc = L; }
   SourceLocation getRParenLoc() const { return RParenLoc; }
   void setRParenLoc(SourceLocation L) { RParenLoc = L; }
 
   /// Determine whether this expression models list-initialization.
+  /// FIXME: We should use a bit to represent it.
----------------
ojhunt wrote:

I'd rephrase this as "we should store this explicitly" rather than propose a specific solution

https://github.com/llvm/llvm-project/pull/228340


More information about the cfe-commits mailing list