[clang] [clang] fix matching of nested template template parameters (PR #130447)
Matheus Izvekov via cfe-commits
cfe-commits at lists.llvm.org
Sun Mar 9 07:42:26 PDT 2025
================
@@ -11363,14 +11363,17 @@ class Sema final : public SemaBase {
/// The context in which we are checking a template parameter list.
enum TemplateParamListContext {
- TPC_ClassTemplate,
- TPC_VarTemplate,
+ // For this context, Class, Variable, TypeAlias, and non-pack Template
+ // Template
+ // Parameters are the same.
+ TPC_Normal,
----------------
mizvekov wrote:
No would be needing to add two actually, TPC_TemplateTemplateParameter and TPC_TemplateTemplateParameterPack.
I think the simplification is worth it, as otherwise we would always be testing four kinds together everywhere.
There is no point in differentiating these cases for the current implementation, and I hope we can find a better name and keep the simplification.
https://github.com/llvm/llvm-project/pull/130447
More information about the cfe-commits
mailing list