================
@@ -5120,6 +5121,10 @@ bool Sema::addInstantiatedParametersToScope(
       // Simple case: not a parameter pack.
       assert(FParamIdx < Function->getNumParams());
       ParmVarDecl *FunctionParam = Function->getParamDecl(FParamIdx);
+      DeclarationName name = FunctionParam->getDeclName();
+      auto _ = llvm::make_scope_exit([&]() {
+        FunctionParam->setDeclName(name);
----------------
erichkeane wrote:

Something about this being done at scope-exist makes me think this is a smell.  
I don't think I understand what is going on here enough with the various names 
enough to know whether this is OK.  Could @zygoloid take a quick look and see 
if this is crazy or not?

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

Reply via email to