hahnjo wrote: Hi @shafik, the issue is an inconsistency in the treatment of template specialization types depending on whether they are the prefix or the "final" type. To stay with the example of the test, the result without this patch is `A<1>` and `A<2>`, but `A<1U>::B<3>` and `A<2U>::B<4>`. This is affecting us downstream (ROOT, Cling, LHC experiments) where we try to normalize user types to a canonical string, irrespective of what the code may have spelled in different occasions. The latter means we cannot use the `Decl`, but we have to recursively normalize all scopes, class names, and template arguments. The inconsistency now causes a problem because we also have a "cheap" normalization routine based on string manipulation that just looks at the integer constant and keeps it without type suffix.
There is no issue for this because the problem is not present anymore in `main`, see https://github.com/llvm/llvm-project/pull/137804 (and it actually took me quite some time to understand how I could trigger the problem upstream without copying thousands of lines from the name normalization). If you insist, I can create an issue and immediately close it (?) but I personally don't see the advantage. The commit message and PR summary already explain that the change forwards the `TPL` and this avoids "avoids type suffixes for integer constants when the type can be inferred from the template parameter." I don't know how to improve this, but I'm open for suggestions. https://github.com/llvm/llvm-project/pull/137806 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits