================
@@ -4077,6 +4084,7 @@ Sema::SubstExpr(Expr *E, const 
MultiLevelTemplateArgumentList &TemplateArgs) {
   TemplateInstantiator Instantiator(*this, TemplateArgs,
                                     SourceLocation(),
                                     DeclarationName());
+  Instantiator.setEvaluateConstraints(false);
----------------
erichkeane wrote:

I believe this ends up being incorrect?  We end up calling SubstExpr pretty 
frequently 'inside' of other constraint expression checking I think, and I 
think we set whether to evaluate constraints with further checks based on the 
current instantiator.

So I think this ends up failing to check constraints in a cascading way.  I DO 
know I tried something similar ot this patch at one point when doing the 
deferred diagnostics and ran into trouble.

IF we are going to do something like this (as I don't have sufficient evidence 
here to block I think), we need to hold this off until after the release so it 
has time to bake.


https://github.com/llvm/llvm-project/pull/74490
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to