1
Fork 0

Return a LocalDefId in get_parent_item.

This commit is contained in:
Camille GILLOT 2021-10-21 19:41:47 +02:00
parent 5a123c265b
commit 60064726ae
51 changed files with 151 additions and 140 deletions

View file

@ -58,7 +58,7 @@ impl<'tcx> TyCtxt<'tcx> {
pub fn provide(providers: &mut Providers) {
providers.parent_module_from_def_id = |tcx, id| {
let hir = tcx.hir();
hir.local_def_id(hir.get_module_parent_node(hir.local_def_id_to_hir_id(id)))
hir.get_module_parent_node(hir.local_def_id_to_hir_id(id))
};
providers.hir_crate = |tcx, ()| tcx.untracked_crate;
providers.crate_hash = map::crate_hash;