support rust-analyzer for board_qemu features

This commit is contained in:
Yu Chen 2022-07-14 10:04:41 +08:00
parent 395a56fc36
commit e15c1cc9a0
3 changed files with 20 additions and 0 deletions

3
.gitignore vendored
View File

@ -1,3 +1,6 @@
.*/*
!.github/*
!.vscode/settings.json
.idea
Cargo.lock
target

13
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,13 @@
{
// Prevent "can't find crate for `test`" error on no_std
// Ref: https://github.com/rust-lang/vscode-rust/issues/729
// For vscode-rust plugin users:
"rust.target": "riscv64gc-unknown-none-elf",
"rust.all_targets": false,
// For Rust Analyzer plugin users:
"rust-analyzer.cargo.target": "riscv64gc-unknown-none-elf",
"rust-analyzer.checkOnSave.allTargets": false,
"rust-analyzer.cargo.features": [
"board_qemu"
]
}

View File

@ -11,3 +11,7 @@ buddy_system_allocator = "0.6"
[profile.release]
debug = true
[features]
board_qemu = []
board_k210 = []