背景
在使用 Visual Studio Code (1.97.2) 进行 GDB 调试时,想使用 x 命令看一下某地址处的数值。出现如下报错:
1 |
-var-create: unable to create variable object |
解决方案
其实,在刚刚开始调试程序时,就以黄色字体给出了解决方案。
1 |
Execute debugger commands using "-exec <command>", for example "-exec info registers" will list registers in use (when GDB is the debugger) |
也就是说: