Unnamed repository; edit this file 'description' to name the repository.
-rw-r--r--crates/rust-analyzer/src/handlers/request.rs6
1 files changed, 5 insertions, 1 deletions
diff --git a/crates/rust-analyzer/src/handlers/request.rs b/crates/rust-analyzer/src/handlers/request.rs
index 27114fef87..dd41991a91 100644
--- a/crates/rust-analyzer/src/handlers/request.rs
+++ b/crates/rust-analyzer/src/handlers/request.rs
@@ -2418,7 +2418,11 @@ fn run_rustfmt(
Ok(None)
}
// rustfmt panicked at lexing/parsing the file
- Some(101) if !rustfmt_not_installed && captured_stderr.starts_with("error[") => {
+ Some(101)
+ if !rustfmt_not_installed
+ && (captured_stderr.starts_with("error[")
+ || captured_stderr.starts_with("error:")) =>
+ {
Ok(None)
}
_ => {