aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
Diffstat (limited to 'crates')
-rw-r--r--crates/rust-analyzer/src/reload.rs30
1 files changed, 16 insertions, 14 deletions
diff --git a/crates/rust-analyzer/src/reload.rs b/crates/rust-analyzer/src/reload.rs
index 031a0cef4..c4f1d098b 100644
--- a/crates/rust-analyzer/src/reload.rs
+++ b/crates/rust-analyzer/src/reload.rs
@@ -269,20 +269,22 @@ impl GlobalState {
269 let project_folders = 269 let project_folders =
270 ProjectFolders::new(&workspaces, &files_config.exclude, workspace_build_data.as_ref()); 270 ProjectFolders::new(&workspaces, &files_config.exclude, workspace_build_data.as_ref());
271 271
272 self.proc_macro_client = match self.config.proc_macro_srv() { 272 if self.proc_macro_client.is_none() {
273 None => None, 273 self.proc_macro_client = match self.config.proc_macro_srv() {
274 Some((path, args)) => match ProcMacroClient::extern_process(path.clone(), args) { 274 None => None,
275 Ok(it) => Some(it), 275 Some((path, args)) => match ProcMacroClient::extern_process(path.clone(), args) {
276 Err(err) => { 276 Ok(it) => Some(it),
277 log::error!( 277 Err(err) => {
278 "Failed to run proc_macro_srv from path {}, error: {:?}", 278 log::error!(
279 path.display(), 279 "Failed to run proc_macro_srv from path {}, error: {:?}",
280 err 280 path.display(),
281 ); 281 err
282 None 282 );
283 } 283 None
284 }, 284 }
285 }; 285 },
286 };
287 }
286 288
287 let watch = match files_config.watcher { 289 let watch = match files_config.watcher {
288 FilesWatcher::Client => vec![], 290 FilesWatcher::Client => vec![],