Remove redundant hashing configuration logic in type interner

This commit is contained in:
Oli Scherer 2022-02-24 12:58:48 +00:00
parent 9327272d02
commit 8d4f4e42af

View file

@ -157,17 +157,12 @@ impl<'tcx> CtxtInterners<'tcx> {
Fingerprint::ZERO
} else {
let mut hasher = StableHasher::new();
let mut hcx = StableHashingContext::new(
let mut hcx = StableHashingContext::ignore_spans(
sess,
&resolutions.definitions,
&*resolutions.cstore,
);
hcx.while_hashing_spans(false, |hcx| {
hcx.with_node_id_hashing_mode(NodeIdHashingMode::HashDefPath, |hcx| {
kind.hash_stable(hcx, &mut hasher);
});
});
kind.hash_stable(&mut hcx, &mut hasher);
hasher.finish()
};