aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Cargo.lock21
-rw-r--r--crates/rust-analyzer/src/config.rs5
2 files changed, 8 insertions, 18 deletions
diff --git a/Cargo.lock b/Cargo.lock
index 61ae8157a..ce88b7403 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -208,20 +208,6 @@ dependencies = [
208] 208]
209 209
210[[package]] 210[[package]]
211name = "crossbeam"
212version = "0.7.3"
213source = "registry+https://github.com/rust-lang/crates.io-index"
214checksum = "69323bff1fb41c635347b8ead484a5ca6c3f11914d784170b158d8449ab07f8e"
215dependencies = [
216 "cfg-if",
217 "crossbeam-channel",
218 "crossbeam-deque",
219 "crossbeam-epoch",
220 "crossbeam-queue",
221 "crossbeam-utils",
222]
223
224[[package]]
225name = "crossbeam-channel" 211name = "crossbeam-channel"
226version = "0.4.2" 212version = "0.4.2"
227source = "registry+https://github.com/rust-lang/crates.io-index" 213source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -1504,12 +1490,13 @@ checksum = "71d301d4193d031abdd79ff7e3dd721168a9572ef3fe51a1517aba235bd8f86e"
1504 1490
1505[[package]] 1491[[package]]
1506name = "salsa" 1492name = "salsa"
1507version = "0.14.2" 1493version = "0.14.3"
1508source = "registry+https://github.com/rust-lang/crates.io-index" 1494source = "registry+https://github.com/rust-lang/crates.io-index"
1509checksum = "6a976dce155e392af3f1aa540ca23a6fc7303a7fef425cb431c464deb263eb54" 1495checksum = "4cd4f099cf7f1d6147aeb313d3fb093d2be1bf71a9fac0122d171c7593206af3"
1510dependencies = [ 1496dependencies = [
1511 "crossbeam", 1497 "crossbeam-utils",
1512 "indexmap", 1498 "indexmap",
1499 "lock_api",
1513 "log", 1500 "log",
1514 "parking_lot", 1501 "parking_lot",
1515 "rand", 1502 "rand",
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs
index 21acfe644..0c7c36716 100644
--- a/crates/rust-analyzer/src/config.rs
+++ b/crates/rust-analyzer/src/config.rs
@@ -9,7 +9,6 @@
9 9
10use std::{ffi::OsString, path::PathBuf}; 10use std::{ffi::OsString, path::PathBuf};
11 11
12use crate::diagnostics::DiagnosticsConfig;
13use flycheck::FlycheckConfig; 12use flycheck::FlycheckConfig;
14use lsp_types::ClientCapabilities; 13use lsp_types::ClientCapabilities;
15use ra_db::AbsPathBuf; 14use ra_db::AbsPathBuf;
@@ -17,6 +16,8 @@ use ra_ide::{AssistConfig, CompletionConfig, HoverConfig, InlayHintsConfig};
17use ra_project_model::{CargoConfig, ProjectJson, ProjectJsonData, ProjectManifest}; 16use ra_project_model::{CargoConfig, ProjectJson, ProjectJsonData, ProjectManifest};
18use serde::Deserialize; 17use serde::Deserialize;
19 18
19use crate::diagnostics::DiagnosticsConfig;
20
20#[derive(Debug, Clone)] 21#[derive(Debug, Clone)]
21pub struct Config { 22pub struct Config {
22 pub client_caps: ClientCapsConfig, 23 pub client_caps: ClientCapsConfig,
@@ -182,8 +183,10 @@ impl Config {
182 log::info!("Config::update({:#})", value); 183 log::info!("Config::update({:#})", value);
183 184
184 let client_caps = self.client_caps.clone(); 185 let client_caps = self.client_caps.clone();
186 let linked_projects = self.linked_projects.clone();
185 *self = Config::new(self.root_path.clone()); 187 *self = Config::new(self.root_path.clone());
186 self.client_caps = client_caps; 188 self.client_caps = client_caps;
189 self.linked_projects = linked_projects;
187 190
188 set(value, "/withSysroot", &mut self.with_sysroot); 191 set(value, "/withSysroot", &mut self.with_sysroot);
189 set(value, "/diagnostics/enable", &mut self.publish_diagnostics); 192 set(value, "/diagnostics/enable", &mut self.publish_diagnostics);