相关疑难解决方法(0)

在 VS Code 中编译 C/C++

我正在尝试使用 cl(通过 Visual Studio 2019 安装)在 VS Code 中编译 C/C++ 代码。我已经按照 MS 网站的建议设置了 json 文件,

https://code.visualstudio.com/docs/cpp/config-msvc

但我仍然收到错误:

cl.exe : The term 'cl.exe' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Run Code Online (Sandbox Code Playgroud)

这是我的 json 文件:

{
"configurations": [
    {
        "name": "Win32",
        "includePath": [
            "${workspaceFolder}/**"
        ],
        "defines": [
            "_DEBUG",
            "UNICODE",
            "_UNICODE"
        ],
        "windowsSdkVersion": "10.0.17763.0", …
Run Code Online (Sandbox Code Playgroud)

c c++ visual-studio-code

7
推荐指数
2
解决办法
1万
查看次数

标签 统计

c ×1

c++ ×1

visual-studio-code ×1