c_cpp_properties.json:
1 { 2 "configurations": [ 3 { 4 "name": "Mac", 5 "includePath": [ 6 "/usr/local/include", 7 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1", 8 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include", 9 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include",10 "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include",11 "${workspaceRoot}"12 ],13 "defines": [],14 "intelliSenseMode": "clang-x64",15 "browse": {16 "path": [17 "/usr/local/include",18 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1",19 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include",20 "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include",21 "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include",22 "${workspaceRoot}"23 ],24 "limitSymbolsToIncludedHeaders": true,25 "databaseFilename": ""26 },27 "macFrameworkPath": [28 "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/System/Library/Frameworks"29 ]30 },31 {32 "name": "Linux",33 "includePath": [34 "/usr/include",35 "/usr/local/include",36 "${workspaceRoot}"37 ],38 "defines": [],39 "intelliSenseMode": "clang-x64",40 "browse": {41 "path": [42 "/usr/include",43 "/usr/local/include",44 "${workspaceRoot}"45 ],46 "limitSymbolsToIncludedHeaders": true,47 "databaseFilename": ""48 }49 },50 {51 "name": "Win32",52 "includePath": [53 "C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/include",54 "${workspaceRoot}"55 ],56 "defines": [57 "_DEBUG",58 "UNICODE"59 ],60 "intelliSenseMode": "msvc-x64",61 "browse": {62 "path": [63 "C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/include/*",64 "${workspaceRoot}"65 ],66 "limitSymbolsToIncludedHeaders": true,67 "databaseFilename": ""68 }69 }70 ],71 "version": 372 }
launch.json:
1 // 使用 IntelliSense 了解相关属性。 2 // 悬停以查看现有属性的描述。 3 // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387 4 { 5 "version": "0.2.0", 6 "configurations": [ 7 { 8 "name": "(lldb) Launch", 9 "type": "cppdbg",10 "request": "launch",11 "program": "${workspaceRoot}/a.out",12 "args": [],13 "stopAtEntry": false,14 "cwd": "${workspaceRoot}",15 "environment": [],16 "externalConsole": true,17 "MIMode": "lldb"18 }
tasks.json:
1 {2 // See https://go.microsoft.com/fwlink/?LinkId=7335583 // for the documentation about the tasks.json format4 "version": "0.1.0",5 "command": "clang", //使用clang编译C文件,如果你使用C++开发,改成clang++6 "isShellCommand": true,7 "args": ["main.c", "-g"],//如果使用的是C++,则改成main.cpp或者相对应的cpp入口文件。如果需要支持C++11,添加"-std=c++11"8 "showOutput": "always"9 }