[llvm] [LLVM] Create `lf_alias` nodes for `typedef` and `using` (PR #153936)
Reid Kleckner via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 20 13:47:29 PDT 2025
https://github.com/rnk commented:
Thanks for the change! I don't have MSVC in front of me at the moment to interrogate when it uses LF_ALIAS records to check the corner cases, but I assume this is what we want to do. I worry about the possibility of ODR violations in cases like:
```
template <typename T> struct Foo { T x; };
int main() {
typedef int myint_t;
Foo<int> v1;
Foo<myint_t> v2; // Hopefully we only have one Foo<int> instantiation in the debug info...
}
```
Does Clang handle the case I have in mind by generating IR in such a way that the Foo composite type records refer to the canonical int type, or the typedef?
https://github.com/llvm/llvm-project/pull/153936
More information about the llvm-commits
mailing list