HashStable in libsyntax.
This commit is contained in:
parent
333c11433b
commit
375a761303
3 changed files with 3 additions and 14 deletions
|
@ -220,11 +220,6 @@ impl<'a> HashStable<StableHashingContext<'a>> for hir::ImplItem {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl_stable_hash_for!(enum ast::CrateSugar {
|
|
||||||
JustCrate,
|
|
||||||
PubCrate,
|
|
||||||
});
|
|
||||||
|
|
||||||
impl<'a> HashStable<StableHashingContext<'a>> for hir::VisibilityKind {
|
impl<'a> HashStable<StableHashingContext<'a>> for hir::VisibilityKind {
|
||||||
fn hash_stable(&self, hcx: &mut StableHashingContext<'a>, hasher: &mut StableHasher) {
|
fn hash_stable(&self, hcx: &mut StableHashingContext<'a>, hasher: &mut StableHasher) {
|
||||||
mem::discriminant(self).hash_stable(hcx, hasher);
|
mem::discriminant(self).hash_stable(hcx, hasher);
|
||||||
|
|
|
@ -159,11 +159,6 @@ where
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl_stable_hash_for!(enum ::syntax::ast::Mutability {
|
|
||||||
Immutable,
|
|
||||||
Mutable
|
|
||||||
});
|
|
||||||
|
|
||||||
impl<'a> ToStableHashKey<StableHashingContext<'a>> for region::Scope {
|
impl<'a> ToStableHashKey<StableHashingContext<'a>> for region::Scope {
|
||||||
type KeyType = region::Scope;
|
type KeyType = region::Scope;
|
||||||
|
|
||||||
|
|
|
@ -722,9 +722,8 @@ pub enum PatKind {
|
||||||
Mac(Mac),
|
Mac(Mac),
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(
|
#[derive(Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
|
||||||
Clone, PartialEq, Eq, PartialOrd, Ord, Hash, RustcEncodable, RustcDecodable, Debug, Copy,
|
RustcEncodable, RustcDecodable, Debug, Copy, HashStable_Generic)]
|
||||||
)]
|
|
||||||
pub enum Mutability {
|
pub enum Mutability {
|
||||||
Mutable,
|
Mutable,
|
||||||
Immutable,
|
Immutable,
|
||||||
|
@ -2334,7 +2333,7 @@ impl PolyTraitRef {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Copy, Clone, RustcEncodable, RustcDecodable, Debug)]
|
#[derive(Copy, Clone, RustcEncodable, RustcDecodable, Debug, HashStable_Generic)]
|
||||||
pub enum CrateSugar {
|
pub enum CrateSugar {
|
||||||
/// Source is `pub(crate)`.
|
/// Source is `pub(crate)`.
|
||||||
PubCrate,
|
PubCrate,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue