aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
authorClemens Wasser <[email protected]>2020-06-10 08:37:26 +0100
committerClemens Wasser <[email protected]>2020-06-10 08:37:26 +0100
commitfe21fc2d259cbe2a32bfee3432f2c51ade079083 (patch)
tree8a7aff5aaf97c0e7e31c4a771e0c1afc73aeca8f /crates
parent33b905883819038ad67476fe14b7b48212a73f93 (diff)
checkOnSafe.features and checkOnSafe.allFeatures now work identically.
Diffstat (limited to 'crates')
-rw-r--r--crates/rust-analyzer/src/config.rs11
1 files changed, 2 insertions, 9 deletions
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs
index 617612dc3..1253db836 100644
--- a/crates/rust-analyzer/src/config.rs
+++ b/crates/rust-analyzer/src/config.rs
@@ -241,15 +241,8 @@ 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 if let Some(new_all_features) = get(value, "/checkOnSave/allFeatures") { 244 *all_features = get(value, "/checkOnSave/allFeatures").unwrap_or(self.cargo.all_features);
245 *all_features = new_all_features; 245 *features = get(value, "/checkOnSave/features").unwrap_or(self.cargo.features.clone());
246 } else {
247 *all_features = self.cargo.all_features;
248 }
249 set(value, "/checkOnSave/features", features);
250 if features.is_empty() && !self.cargo.features.is_empty() {
251 *features = self.cargo.features.clone();
252 }
253 } 246 }
254 } 247 }
255 }; 248 };