-
Notifications
You must be signed in to change notification settings - Fork 256
Description
This may be useful for both the WSL scenario and for external
debugging where the source path on the client (vscode) is not the same as the debugger (gdbserver, possibly running on wsl) sees:
I suggest to add a sourceFileMap
setting. This would need to applied anywhere the client passes paths (breakpoints, "go to cursor") and when the client receives paths (I guess that's the stack only).
Originally posted by @GitMensch in #467 (comment)
People are using their own gdb-init scripts to [do path substitutions] - No help from extension needed.
The bigger problem is how breakpoints are set and how stack traces are interpreted. Disassembly is affected as well.. How we look for static variables is also affected -- as in we have to implement what gdb does. VSCode manages breakpoints with paths (file/line) that it sees. It wasn't clear to me how gdb handled file/line breakpoints and if clients (us) have to do the reverse mapping. [..m]
cpptools/cppdbg added support for source maps. We can check to see what all they do with that info.
Originally posted by @haneefdm in #467 (comment)