1
Fork 0

Store hir_id_to_def_id in OwnerInfo.

This commit is contained in:
Camille GILLOT 2021-11-21 19:04:47 +01:00 committed by Santiago Pastorino
parent 17dfae79bb
commit 80132c3ce4
No known key found for this signature in database
GPG key ID: 8131A24E0C79EFAF
5 changed files with 31 additions and 19 deletions

View file

@ -208,8 +208,13 @@ impl<'tcx, HirCtx: crate::HashStableContext> HashStable<HirCtx> for OwnerNodes<'
fn hash_stable(&self, hcx: &mut HirCtx, hasher: &mut StableHasher) {
// We ignore the `nodes` and `bodies` fields since these refer to information included in
// `hash` which is hashed in the collector and used for the crate hash.
let OwnerNodes { hash_including_bodies, hash_without_bodies: _, nodes: _, bodies: _ } =
*self;
let OwnerNodes {
hash_including_bodies,
hash_without_bodies: _,
nodes: _,
bodies: _,
local_id_to_def_id: _,
} = *self;
hash_including_bodies.hash_stable(hcx, hasher);
}
}