remove some manual hash stable impls
This commit is contained in:
parent
7dfdd64433
commit
d3ad264a91
5 changed files with 15 additions and 89 deletions
|
@ -3,6 +3,7 @@ use rustc_index::bit_set;
|
|||
use rustc_index::vec;
|
||||
use smallvec::SmallVec;
|
||||
use std::hash::{BuildHasher, Hash, Hasher};
|
||||
use std::marker::PhantomData;
|
||||
use std::mem;
|
||||
|
||||
#[cfg(test)]
|
||||
|
@ -261,6 +262,10 @@ impl<CTX> HashStable<CTX> for ! {
|
|||
}
|
||||
}
|
||||
|
||||
impl<CTX, T> HashStable<CTX> for PhantomData<T> {
|
||||
fn hash_stable(&self, _ctx: &mut CTX, _hasher: &mut StableHasher) {}
|
||||
}
|
||||
|
||||
impl<CTX> HashStable<CTX> for ::std::num::NonZeroU32 {
|
||||
#[inline]
|
||||
fn hash_stable(&self, ctx: &mut CTX, hasher: &mut StableHasher) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue