[clang] [Clang] Added explanation why a is constructible evaluated to false. (PR #143309)
Shamshura Egor via cfe-commits
cfe-commits at lists.llvm.org
Thu Jun 12 12:59:59 PDT 2025
================
@@ -2253,6 +2260,53 @@ static void DiagnoseNonTriviallyCopyableReason(Sema &SemaRef,
}
}
+static void DiagnoseNonConstructibleReason(
+ Sema &SemaRef, SourceLocation Loc,
+ const llvm::SmallVector<clang::QualType, 1> &Ts) {
+ for (const auto &ArgTy : Ts) {
+ if (ArgTy->isVoidType())
+ SemaRef.Diag(Loc, diag::note_unsatisfied_trait_reason)
+ << diag::TraitNotSatisfiedReason::CVVoidType;
+ }
+
+ QualType T = Ts[0];
----------------
egorshamshura wrote:
Added early-exit, thanks
https://github.com/llvm/llvm-project/pull/143309
More information about the cfe-commits
mailing list