variables are not being shown in VSCode but GDB is showing them
See original GitHub issuethe setup is:
- VSCode running on Windows
- GDB running on linux
- the ssh extension is being used
- process is C/C++
The members of a struct are shown in the variable list but they have no value.
I captured the log of the DAP communication and I can see that the variables are being requested and returned empty:
for example:
{
"type": "response",
"request_seq": 58,
"success": true,
"command": "variables",
"body": {
"variables": [
{
"name": "next",
"value": "",
"type": "struct cdbtype_ *",
"evaluateName": "((cdbtype *)0x7408b2eaa3e8)->next",
"variablesReference": 1012
},
{
"name": "pif_type",
"value": "",
"type": "enum pif_types_",
"evaluateName": "((cdbtype *)0x7408b2eaa3e8)->pif_type",
"variablesReference": 0
},
If I check the variables inside GDB I can see their value correctly. Given the DAP shows empty strings I believe the problem might be in OpenDebugAD7
.
Happy to collect more info if needed.
Issue Analytics
- State:
- Created a month ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
My VSCode debugger dosen't show any variable value ...
The c++ debugger dosen't show any values which are readable. ... Variable not showing their values during debugging. my launch.json:
Read more >debugger not showing variables and callstack #51
Debugging works, but no local variables. The debugger is getting them because i can hover over variables in the code and see their...
Read more >Configure launch.json for C/C++ debugging in ...
The path to the debugger (such as gdb). When only the executable is specified, it will search the operating system's PATH variable for...
Read more >Get Started with C++ and MinGW-w64 in Visual Studio Code
Using GCC with MinGW. In this tutorial, you configure Visual Studio Code to use the GCC C++ compiler (g++) and GDB debugger from...
Read more >Debugger Extension
Variable values shown in hovers or inlined in the source. ... It is called Mock Debug because it does not talk to a...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Agreed, thanks - I think this can be closed
Yep. I believe this would have to be filed at https://sourceware.org/bugzilla/ in order for this to be fixed.