Recognize proc macro server unexpectedly exiting and report the exit code

This commit is contained in:
Lukas Wirth 2024-01-08 11:40:27 +01:00
parent f5f7ddae23
commit 21a953fe37
3 changed files with 52 additions and 12 deletions

View file

@ -24,7 +24,8 @@ fn main() -> std::io::Result<()> {
#[cfg(not(any(feature = "sysroot-abi", rust_analyzer)))]
fn run() -> io::Result<()> {
panic!("proc-macro-srv-cli requires the `sysroot-abi` feature to be enabled");
eprintln!("proc-macro-srv-cli requires the `sysroot-abi` feature to be enabled");
std::process::exit(70);
}
#[cfg(any(feature = "sysroot-abi", rust_analyzer))]