2023年東莞疫情最新消息seo關(guān)鍵詞首頁排名代發(fā)
多文件編譯備忘,帶注釋的地方都需要注意!!!
launch.json文件
{// 使用 IntelliSense 了解相關(guān)屬性。 // 懸停以查看現(xiàn)有屬性的描述。// 欲了解更多信息,請訪問: https://go.microsoft.com/fwlink/?linkid=830387"version": "0.2.0","configurations": [{"name": "g++.exe - 生成和調(diào)試活動文件","type": "cppdbg","request": "launch","program": "${fileDirname}/out.exe",//1、 文件目錄 執(zhí)行程序.exe路徑"args": [],"stopAtEntry": false,"cwd": "${fileDirname}", //2、文件目錄"environment": [],"externalConsole": true, //3、 顯示控制臺窗口"MIMode": "gdb","miDebuggerPath": "D:\\App\\Microsoft VS Code\\mingw64\\bin\\gdb.exe", //4、 gdb.exe路徑"setupCommands": [{"description": "為 gdb 啟用整齊打印","text": "-enable-pretty-printing","ignoreFailures": true},{"description": "將反匯編風(fēng)格設(shè)置為 Intel","text": "-gdb-set disassembly-flavor intel","ignoreFailures": true}],"preLaunchTask": "C/C++: g++.exe 生成活動文件" //鏈接task.json,這個名稱必須要與task.json中的label名稱一致否則會編譯出錯}]
}
task.json文件
{"tasks": [{"type": "cppbuild","label": "C/C++: g++.exe 生成活動文件", //1、 與launch.json中preLaunchTask的名稱一致"command": "D:\\App\\Microsoft VS Code\\mingw64\\bin\\g++.exe", //2、 c++編譯器g++.exe的路徑"args": ["-fdiagnostics-color=always","-g","${fileDirname}/*.cpp", //"${file}", //多文件編譯"-o","${fileDirname}/out.exe" //"${fileDirname}\\${fileBasenameNoExtension}.exe" //多文件編譯成功生成的可執(zhí)行文件.exe],"options": {"cwd": "${fileDirname}"},"problemMatcher": ["$gcc"],"group": {"kind": "build","isDefault": true},"detail": "調(diào)試器生成的任務(wù)。"}],"version": "2.0.0"
}