VS Code will not build c++ programs with multiple .ccp source files

前端 未结 7 1926
后悔当初
后悔当初 2020-11-29 07:58

Note that I\'m using VS Code on Ubuntu 17.10 and using the GCC Compiler.

I\'m having trouble building a simple program which makes use of additional .ccp files. I\'m

7条回答
  •  粉色の甜心
    2020-11-29 08:07

    "tasks": [
        {
            "label": "echo",
            "type": "shell",
            "command": "g++",
            "args":[
                "-g","main.cpp","cat.cpp"
            ],
            "group": {
                "kind": "build",
                "isDefault": true
            }
        }
    

    Just add cat.cpp in args and then try to run. It should run without error on VS code

提交回复
热议问题