================ @@ -5585,11 +5585,12 @@ bool Sema::CheckTemplateArgumentList( ContextRAII Context(*this, NewContext); CXXThisScopeRAII(*this, RD, ThisQuals, RD != nullptr); - MultiLevelTemplateArgumentList MLTAL = getTemplateInstantiationArgs( - Template, NewContext, /*Final=*/false, CanonicalConverted, - /*RelativeToPrimary=*/true, - /*Pattern=*/nullptr, - /*ForConceptInstantiation=*/true); + MultiLevelTemplateArgumentList MLTAL = + getTemplateInstantiationArgs(Template, Template->getDeclContext(), + /*Final=*/false, CanonicalConverted, + /*RelativeToPrimary=*/true, + /*Pattern=*/nullptr, + /*ForConceptInstantiation=*/true); ---------------- zyn0217 wrote:
The `NewContext` argument didn't actually make any difference to `getTemplateInstantiationArgs()` previously, as it would always move to `Template->getDeclContext()` for the next traversal if the Innermost parameter (which is `CanonicalConverted`) was present. So I changed it to `Template->getDeclContext()` to clarify the behavior. However, I can revert the changes on `getTemplateInstantiationArgs()` after @sdkrystian's refactoring patch, so this is left only for the time being. https://github.com/llvm/llvm-project/pull/102857 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits