Use head span for rustc_on_unimplemented's enclosing_scope attr
This commit is contained in:
parent
84f0c3f79a
commit
c23fe81764
8 changed files with 120 additions and 197 deletions
|
@ -526,7 +526,7 @@ impl<'a, 'tcx> InferCtxtExt<'tcx> for InferCtxt<'a, 'tcx> {
|
|||
});
|
||||
|
||||
let enclosing_scope_span =
|
||||
tcx.hir().span_with_body(tcx.hir().local_def_id_to_hir_id(body));
|
||||
tcx.hir().span(tcx.hir().local_def_id_to_hir_id(body));
|
||||
|
||||
err.span_label(enclosing_scope_span, s);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue