[clang] [Clang][Sema] Diagnosis for constexpr constructor not initializing a union member (PR #81225)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Feb 21 06:38:58 PST 2024
================
@@ -2393,6 +2391,17 @@ static bool CheckConstexprFunctionBody(Sema &SemaRef, const FunctionDecl *Dcl,
Kind))
return false;
}
+ } else if (!Constructor->isDelegatingConstructor()) {
----------------
mahtohappy wrote:
Hi, the check before here in the file only checks for non-templated, non-delegating constructors initializing the class where union is member, and that produces a different warning.
And if you're why this whole patch, then I've added the issue it resolves.
https://github.com/llvm/llvm-project/pull/81225
More information about the cfe-commits
mailing list