Auto merge of #12171 - lnicola:proc-macros-dont-invalidate-state, r=Veykril

fix: Try not to invalidate state when the proc macro preference didn't change

This appears to fix #12027, but I'm not sure.
This commit is contained in:
bors 2022-05-06 10:14:05 +00:00
commit db1434b34f

View file

@ -55,10 +55,13 @@ impl GlobalState {
self.reload_flycheck(); self.reload_flycheck();
} }
// Apply experimental feature flags. if self.analysis_host.raw_database().enable_proc_attr_macros()
self.analysis_host != self.config.expand_proc_attr_macros()
.raw_database_mut() {
.set_enable_proc_attr_macros(self.config.expand_proc_attr_macros()); self.analysis_host
.raw_database_mut()
.set_enable_proc_attr_macros(self.config.expand_proc_attr_macros());
}
} }
pub(crate) fn current_status(&self) -> lsp_ext::ServerStatusParams { pub(crate) fn current_status(&self) -> lsp_ext::ServerStatusParams {