(Some(h), _) => h,
(None, Some(item_did)) => {
match item_did.as_local() {
- Some(item_did) => self.tcx.hir().as_local_hir_id(item_did),
+ Some(item_did) => self.tcx.hir().local_def_id_to_hir_id(item_did),
None => {
// If non-local, no need to check anything.
return;