We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 309c671 + 63b82dd commit b250e0fCopy full SHA for b250e0f
src/tools/rust-analyzer/crates/project-model/src/sysroot.rs
@@ -444,13 +444,14 @@ fn discover_sysroot_src_dir_or_add_component(
444
get_rust_src(sysroot_path)
445
})
446
.ok_or_else(|| {
447
- let error = "\
+ tracing::error!(%sysroot_path, "can't load standard library, try installing `rust-src`");
448
+ format_err!(
449
+ "\
450
can't load standard library from sysroot
451
{sysroot_path}
452
(discovered via `rustc --print sysroot`)
-try installing the Rust source the same way you installed rustc";
- tracing::error!(error);
453
- format_err!(error)
+try installing `rust-src` the same way you installed `rustc`"
454
+ )
455
456
}
457
0 commit comments