================
@@ -7416,10 +7416,11 @@ NamedDecl *Sema::ActOnVariableDeclarator(
     tryToFixVariablyModifiedVarType(TInfo, R, D.getIdentifierLoc(),
                                     /*DiagID=*/0);
 
-  if (const AutoType *AutoT = R->getAs<AutoType>())
-    CheckConstrainedAuto(
-        AutoT,
-        TInfo->getTypeLoc().getContainedAutoTypeLoc().getConceptNameLoc());
+  if (const AutoType *AutoT = R->getAs<AutoType>()) {
+    AutoTypeLoc Loc = TInfo->getTypeLoc().getContainedAutoTypeLoc();
----------------
Endilll wrote:

I applied your suggestion, leaving error recovery issue for later, and also 
added tests for pointer and reference types. Thank you again for your excellent 
analysis.

If that's how it should be fixed today, I'm fine proceeding this way. That 
said, I find the approach somewhat backwards: morally I'm interested whether 
there's a constrained auto that might be using a concept, but we implement it 
asking for _location_ of constrained auto, and get the AST node for constrained 
auto from it.

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

Reply via email to