Skip to content

Conversation

sdkrystian
Copy link
Member

This is necessary to ensure that functions declared in different translation units whose parameter types only differ in top-level cv-qualification generate the same USR.

For example:

// A.cpp
void f(const int x); // c:@F@f#1I#

// B.cpp
void f(int x);       // c:@F@f#I#

With the proposed changes, the USR for both functions will be c:@F@f#I#.

@llvmbot llvmbot added the clang Clang issues not falling into any other category label Oct 4, 2023
@mizvekov
Copy link
Contributor

mizvekov commented Oct 4, 2023

Also, would you make sure to add a test case for this?

Thanks.

@sdkrystian
Copy link
Member Author

@mizvekov Sure, I'll take care of that tomorrow

@mizvekov
Copy link
Contributor

@sdkrystian ping, do you still intend to continue this? Just adding your example as a test case would be fine.

@sdkrystian
Copy link
Member Author

@mizvekov I totally forgot about this PR, sorry! I'll add a test and merge tomorrow :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang Clang issues not falling into any other category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants