我无法在Visual Studio代码中使用“开始调试”选项

时间:2020-11-08 17:05:19

标签: c++ c json gcc visual-studio-code

我是编码领域的新手,这是我第一次希望将问题正确地放在堆栈溢出上。

它总是要求配置launch.json,但是添加任何配置都不能解决我的问题。 我的launch.json现在看起来像这样:-

{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
    {
        "name": "(gdb) Launch",
        "type": "cppdbg",
        "request": "launch",
        "program": "enter program name, for example ${workspaceFolder}/a.out",
        "args": [],
        "stopAtEntry": false,
        "cwd": "${workspaceFolder}",
        "environment": [],
        "externalConsole": false,
        "MIMode": "gdb",
        "setupCommands": [
            {
                "description": "Enable pretty-printing for gdb",
                "text": "-enable-pretty-printing",
                "ignoreFailures": true
            }
        ]``
    }
  
]}

并且每当直接从launch.json直接构建它时,都会出现此消息错误:-

 "launch:program 'enter program name, for example /home/prabhav/Documents/a.out' does not exist.

these are some of the options given for adding configuration

0 个答案:

没有答案