about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAleksey Kladov <aleksey.kladov@gmail.com>2020-07-03 17:19:00 +0200
committerAleksey Kladov <aleksey.kladov@gmail.com>2020-07-03 17:19:00 +0200
commitb8ef8539a6fb2ba9bbeeade460a08928abd6cc1b (patch)
tree8c917fb2a9f2595405f5eaaf6b1640e61ce09d33
parentf5a4a4b46e706697abe4bd136503ecc09aa23b61 (diff)
downloadrust-b8ef8539a6fb2ba9bbeeade460a08928abd6cc1b.tar.gz
rust-b8ef8539a6fb2ba9bbeeade460a08928abd6cc1b.zip
Fix workspace reloading
-rw-r--r--crates/rust-analyzer/src/config.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs
index 21acfe6445e..0c7c3671681 100644
--- a/crates/rust-analyzer/src/config.rs
+++ b/crates/rust-analyzer/src/config.rs
@@ -9,7 +9,6 @@
 
 use std::{ffi::OsString, path::PathBuf};
 
-use crate::diagnostics::DiagnosticsConfig;
 use flycheck::FlycheckConfig;
 use lsp_types::ClientCapabilities;
 use ra_db::AbsPathBuf;
@@ -17,6 +16,8 @@ use ra_ide::{AssistConfig, CompletionConfig, HoverConfig, InlayHintsConfig};
 use ra_project_model::{CargoConfig, ProjectJson, ProjectJsonData, ProjectManifest};
 use serde::Deserialize;
 
+use crate::diagnostics::DiagnosticsConfig;
+
 #[derive(Debug, Clone)]
 pub struct Config {
     pub client_caps: ClientCapsConfig,
@@ -182,8 +183,10 @@ impl Config {
         log::info!("Config::update({:#})", value);
 
         let client_caps = self.client_caps.clone();
+        let linked_projects = self.linked_projects.clone();
         *self = Config::new(self.root_path.clone());
         self.client_caps = client_caps;
+        self.linked_projects = linked_projects;
 
         set(value, "/withSysroot", &mut self.with_sysroot);
         set(value, "/diagnostics/enable", &mut self.publish_diagnostics);