Use the interned stable hash as plain hash.
This commit is contained in:
parent
d47424b833
commit
9d86e6abaf
2 changed files with 6 additions and 4 deletions
|
@ -156,7 +156,11 @@ impl<T> Deref for WithStableHash<T> {
|
|||
impl<T: Hash> Hash for WithStableHash<T> {
|
||||
#[inline]
|
||||
fn hash<H: Hasher>(&self, s: &mut H) {
|
||||
self.internee.hash(s)
|
||||
if self.stable_hash != Fingerprint::ZERO {
|
||||
self.stable_hash.hash(s)
|
||||
} else {
|
||||
self.internee.hash(s)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue