aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
Diffstat (limited to 'crates')
-rw-r--r--crates/rust-analyzer/src/config.rs6
1 files changed, 5 insertions, 1 deletions
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs
index 320414ecf..617612dc3 100644
--- a/crates/rust-analyzer/src/config.rs
+++ b/crates/rust-analyzer/src/config.rs
@@ -241,7 +241,11 @@ impl Config {
241 set(value, "/checkOnSave/extraArgs", extra_args); 241 set(value, "/checkOnSave/extraArgs", extra_args);
242 set(value, "/checkOnSave/command", command); 242 set(value, "/checkOnSave/command", command);
243 set(value, "/checkOnSave/allTargets", all_targets); 243 set(value, "/checkOnSave/allTargets", all_targets);
244 set(value, "/checkOnSave/allFeatures", all_features); 244 if let Some(new_all_features) = get(value, "/checkOnSave/allFeatures") {
245 *all_features = new_all_features;
246 } else {
247 *all_features = self.cargo.all_features;
248 }
245 set(value, "/checkOnSave/features", features); 249 set(value, "/checkOnSave/features", features);
246 if features.is_empty() && !self.cargo.features.is_empty() { 250 if features.is_empty() && !self.cargo.features.is_empty() {
247 *features = self.cargo.features.clone(); 251 *features = self.cargo.features.clone();