1
1
use rustc_data_structures:: stable_hasher:: { HashStable , StableHasher , ToStableHashKey } ;
2
2
3
3
use crate :: hir:: {
4
- AttributeMap , BodyId , Crate , Expr , ForeignItemId , ImplItemId , ItemId , OwnerNodes , TraitItemId ,
5
- Ty ,
4
+ AttributeMap , BodyId , Crate , ForeignItemId , ImplItemId , ItemId , OwnerNodes , TraitItemId ,
6
5
} ;
7
6
use crate :: hir_id:: { HirId , ItemLocalId } ;
8
7
use rustc_span:: def_id:: DefPathHash ;
@@ -14,8 +13,6 @@ pub trait HashStableContext:
14
13
rustc_ast:: HashStableContext + rustc_target:: HashStableContext
15
14
{
16
15
fn hash_body_id ( & mut self , _: BodyId , hasher : & mut StableHasher ) ;
17
- fn hash_hir_expr ( & mut self , _: & Expr < ' _ > , hasher : & mut StableHasher ) ;
18
- fn hash_hir_ty ( & mut self , _: & Ty < ' _ > , hasher : & mut StableHasher ) ;
19
16
}
20
17
21
18
impl < HirCtx : crate :: HashStableContext > ToStableHashKey < HirCtx > for HirId {
@@ -96,18 +93,6 @@ impl<HirCtx: crate::HashStableContext> HashStable<HirCtx> for BodyId {
96
93
// want to pick up on a reference changing its target, so we hash the NodeIds
97
94
// in "DefPath Mode".
98
95
99
- impl < HirCtx : crate :: HashStableContext > HashStable < HirCtx > for Expr < ' _ > {
100
- fn hash_stable ( & self , hcx : & mut HirCtx , hasher : & mut StableHasher ) {
101
- hcx. hash_hir_expr ( self , hasher)
102
- }
103
- }
104
-
105
- impl < HirCtx : crate :: HashStableContext > HashStable < HirCtx > for Ty < ' _ > {
106
- fn hash_stable ( & self , hcx : & mut HirCtx , hasher : & mut StableHasher ) {
107
- hcx. hash_hir_ty ( self , hasher)
108
- }
109
- }
110
-
111
96
impl < ' tcx , HirCtx : crate :: HashStableContext > HashStable < HirCtx > for OwnerNodes < ' tcx > {
112
97
fn hash_stable ( & self , hcx : & mut HirCtx , hasher : & mut StableHasher ) {
113
98
// We ignore the `nodes` and `bodies` fields since these refer to information included in
0 commit comments