From ad52c46478f0a9fbaa81e91156b18a577717a1f6 Mon Sep 17 00:00:00 2001 From: David Barsky Date: Thu, 19 Sep 2024 15:19:08 -0400 Subject: [PATCH] analysis-stats: respect --disable-proc-macros flag --- crates/rust-analyzer/src/cli/analysis_stats.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/crates/rust-analyzer/src/cli/analysis_stats.rs b/crates/rust-analyzer/src/cli/analysis_stats.rs index 44e56645ba..2134b033f3 100644 --- a/crates/rust-analyzer/src/cli/analysis_stats.rs +++ b/crates/rust-analyzer/src/cli/analysis_stats.rs @@ -77,7 +77,11 @@ impl flags::AnalysisStats { let metadata_time = db_load_sw.elapsed(); let load_cargo_config = LoadCargoConfig { load_out_dirs_from_check: !self.disable_build_scripts, - with_proc_macro_server: ProcMacroServerChoice::Sysroot, + with_proc_macro_server: if self.disable_proc_macros { + ProcMacroServerChoice::None + } else { + ProcMacroServerChoice::Sysroot + }, prefill_caches: false, };