rust环境配置
安装cargo
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
vscode插件, gdb打印的参数不全,会丢失变量,用lldb
ext install rust-lang.rust
ext install vadimcn.vscode-lldb
调试配置
tasks.json
{ "version": "2.0.0", "tasks": [ { "label": "build", "type": "shell", "command": "cargo build" } ] }
launsh.json
{ "version": "0.2.0", "configurations": [ { "name": "rust_debug", "type": "lldb", "request": "launch", "program": "${workspaceRoot}/target/debug/${workspaceRootFolderName}", "cwd": "${workspaceRoot}", "preLaunchTask": "build" } ] }