VScode 调试go程序报错,需要更改glaunch.json文件

{
    // 使用 IntelliSense 了解相关属性。 
    // 悬停以查看现有属性的描述。
    // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    
    "go.toolsEnvVars": {
    "GOOS": "js",
    "GOARCH": "wasm"
    },
    
    "configurations": [

        {
            "name": "Launch test function",
            "type": "go",
            "request": "launch",
            "mode": "auto",
            "program": "${workspaceFolder}",
            "cwd": "${workspaceRoot}",
            "env": {},
            "args": []
        }

    ]
}

你可能感兴趣的:(vscode,golang,json)