Closed
Description
Currently, if a class scope explicit specialization of a member function template of a class template has the same type as another non-template member function, they will both generate the same USR. This is because we generate the explicit specializations USR from the CXXMethodDecl
returned by ClassScopeFunctionSpecializationDecl::getSpecialization
. For example:
template<typename T>
struct A
{
void f(int); // #1
template<typename U>
void f(U); // #2
template<>
void f<int>(int); // #3
};
Currently, functions 1 and 3 generate the same USR. This can be fixed by generating the USR for function 3 using the ClassScopeFunctionSpecializationDecl
.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Done
Milestone
Relationships
Development
No branches or pull requests
Activity
sdkrystian commentedon Jul 8, 2024
Will be fixed by llvm/llvm-project#98027.