Rust: fix LoadCargoConfig defaults (proc_macro_processes must be >= 1)

Setting proc_macro_processes to 0 causes an index-out-of-bounds panic
in ProcMacroServerPool::new when the proc macro server is enabled.
Use the same defaults as rust-analyzer itself (1 each).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
Taus
2026-04-15 15:29:00 +00:00
parent 87472288c3
commit 87a0ed190f

View File

@@ -197,8 +197,8 @@ impl Config {
load_out_dirs_from_check: true,
with_proc_macro_server: self.proc_macro_server_choice(dir),
prefill_caches: false,
num_worker_threads: 0,
proc_macro_processes: 0,
num_worker_threads: 1,
proc_macro_processes: 1,
},
)
}