We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 03bfbe1 commit 4b890f3Copy full SHA for 4b890f3
compiler/rustc_typeck/src/coherence/inherent_impls_overlap.rs
@@ -76,17 +76,17 @@ impl<'tcx> InherentOverlapChecker<'tcx> {
76
let name = item1.ident(self.tcx).normalize_to_macros_2_0();
77
let mut err = struct_span_err!(
78
self.tcx.sess,
79
- self.tcx.span_of_impl(item1.def_id).unwrap(),
+ self.tcx.def_span(item1.def_id),
80
E0592,
81
"duplicate definitions with name `{}`",
82
name
83
);
84
err.span_label(
85
86
format!("duplicate definitions for `{}`", name),
87
88
89
- self.tcx.span_of_impl(item2.def_id).unwrap(),
+ self.tcx.def_span(item2.def_id),
90
format!("other definition for `{}`", name),
91
92
0 commit comments