mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-25 04:23:25 +00:00
Added the rust-analyzer.checkOnSave.features option.
This commit is contained in:
parent
684b6fa1b8
commit
47ef544fa5
2 changed files with 12 additions and 1 deletions
|
@ -242,7 +242,10 @@ impl Config {
|
|||
set(value, "/checkOnSave/command", command);
|
||||
set(value, "/checkOnSave/allTargets", all_targets);
|
||||
set(value, "/checkOnSave/allFeatures", all_features);
|
||||
*features = self.cargo.features.clone();
|
||||
set(value, "/checkOnSave/features", features);
|
||||
if features.is_empty() && !self.cargo.features.is_empty() {
|
||||
*features = self.cargo.features.clone();
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
@ -322,6 +322,14 @@
|
|||
"default": false,
|
||||
"markdownDescription": "Check with all features (will be passed as `--all-features`)"
|
||||
},
|
||||
"rust-analyzer.checkOnSave.features": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"default": [],
|
||||
"description": "List of features to activate. Set to `rust-analyzer.cargo.features` if empty."
|
||||
},
|
||||
"rust-analyzer.inlayHints.enable": {
|
||||
"type": "boolean",
|
||||
"default": true,
|
||||
|
|
Loading…
Reference in a new issue