Skip to content

Commit 42a92eb

Browse files
committed
Correct Key impl for HirId.
1 parent 1fcc440 commit 42a92eb

File tree

1 file changed

+2
-2
lines changed
  • compiler/rustc_query_impl/src

1 file changed

+2
-2
lines changed

compiler/rustc_query_impl/src/keys.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -552,11 +552,11 @@ impl Key for HirId {
552552
}
553553

554554
fn default_span(&self, tcx: TyCtxt<'_>) -> Span {
555-
self.owner.default_span(tcx)
555+
tcx.hir().span(*self)
556556
}
557557

558558
#[inline(always)]
559559
fn key_as_def_id(&self) -> Option<DefId> {
560-
Some(self.owner.to_def_id())
560+
None
561561
}
562562
}

0 commit comments

Comments
 (0)