We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c5d82ed commit 1e4adafCopy full SHA for 1e4adaf
2 files changed
compiler/rustc_metadata/src/errors.rs
@@ -692,6 +692,7 @@ pub struct CrateLocationUnknownType<'a> {
692
#[primary_span]
693
pub span: Span,
694
pub path: &'a Path,
695
+ pub crate_name: Symbol,
696
}
697
698
#[derive(Diagnostic)]
compiler/rustc_metadata/src/locator.rs
@@ -1024,7 +1024,7 @@ impl CrateError {
1024
if !locator.crate_rejections.via_filename.is_empty() {
1025
let mismatches = locator.crate_rejections.via_filename.iter();
1026
for CrateMismatch { path, .. } in mismatches {
1027
- sess.emit_err(CrateLocationUnknownType { span, path: &path });
+ sess.emit_err(CrateLocationUnknownType { span, path: &path, crate_name });
1028
sess.emit_err(LibFilenameForm {
1029
span,
1030
dll_prefix: &locator.dll_prefix,
0 commit comments