Correct Key impl for HirId.
This commit is contained in:
parent
273b54d6ac
commit
6e76599f5f
1 changed files with 2 additions and 2 deletions
|
@ -565,11 +565,11 @@ impl Key for HirId {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn default_span(&self, tcx: TyCtxt<'_>) -> Span {
|
fn default_span(&self, tcx: TyCtxt<'_>) -> Span {
|
||||||
self.owner.default_span(tcx)
|
tcx.hir().span(*self)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline(always)]
|
#[inline(always)]
|
||||||
fn key_as_def_id(&self) -> Option<DefId> {
|
fn key_as_def_id(&self) -> Option<DefId> {
|
||||||
Some(self.owner.to_def_id())
|
None
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue