[clang] Reapply "[Clang] Transform lambda's constraints when instantiating parameter mapping (PR #207966)

Matheus Izvekov via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 10 06:49:47 PDT 2026


================
@@ -1002,8 +1005,13 @@ ExprResult ConstraintSatisfactionChecker::EvaluateSlow(
       const_cast<NamedDecl *>(Template), Constraint.getSourceRange());
 
   TemplateArgumentListInfo OutArgs(Ori->LAngleLoc, Ori->RAngleLoc);
-  if (S.SubstTemplateArguments(Ori->arguments(), *SubstitutedArgs, OutArgs) ||
-      Trap.hasErrorOccurred()) {
+
+  if (ConceptId == TopLevelConceptId) {
----------------
mizvekov wrote:

It's that I don't see that we impose on `ConceptReference` any of the constraints that would allow comparing them like this with a well defined meaning. Ie if I had seen two declarations compared instead, I would know exactly what it means and where that's appropriate. But not so for ConceptReference.

I think this would be an easy change, and you could just compare ConceptSpecializationDecls instead?

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


More information about the cfe-commits mailing list