mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-14 02:49:40 +00:00
Fix librustdoc error due to as_local_hir_id
changes
This commit is contained in:
parent
fe7531579d
commit
b9ba521e95
@ -646,8 +646,8 @@ impl<'a, 'b> ExtraInfo<'a, 'b> {
|
||||
let hir_id = match (self.hir_id, self.item_did) {
|
||||
(Some(h), _) => h,
|
||||
(None, Some(item_did)) => {
|
||||
match self.tcx.hir().as_local_hir_id(item_did) {
|
||||
Some(hir_id) => hir_id,
|
||||
match item_did.as_local() {
|
||||
Some(item_did) => self.tcx.hir().as_local_hir_id(item_did),
|
||||
None => {
|
||||
// If non-local, no need to check anything.
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user