[llvm] [LLVM] Create `lf_alias` nodes for `typedef` and `using` (PR #153936)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 5 03:34:13 PST 2025
Walnut356 wrote:
>Are able to step-debug a binary generated with your PR? Before we merge this I'd like to be sure we're not breaking the user experience when debugging with the Visual Studio debugger.
Very cool discovery:
This patch works via WinDbg
<img width="1522" height="825" alt="image" src="https://github.com/user-attachments/assets/8090195c-4c97-4a8a-a0a6-d75d7bc8a334" />
But not in Visual Studio or with the C/C++ extension.
EXCEPT you *can* cast variables to the typedef type??
<img width="249" height="121" alt="image" src="https://github.com/user-attachments/assets/f24d49a4-7cd3-464c-9ad0-b0a921b38164" />
Which leads to a really funny scenario where you can typecast the stack location of the variable and view it as intended, even though it'll error if you try to inspect it directly
<img width="305" height="91" alt="image" src="https://github.com/user-attachments/assets/f818104c-1ab3-4718-bc34-9f052e415652" />
Putting that in the watch tab looks through the typedef
<img width="1135" height="22" alt="image" src="https://github.com/user-attachments/assets/34e5b8ed-ead7-4402-b5c0-3215879583b0" />
So uhh... equal parts baffling and hilarious. With that context, it looks like visual studio not working is almost definitely a bug. I've submitted a ticket with them [here](https://developercommunity.visualstudio.com/t/Debugger-expression-parser-cannot-resolv/10994117) so hopefully that can get resolved at some point.
https://github.com/llvm/llvm-project/pull/153936
More information about the llvm-commits
mailing list