11use  crate :: hir; 
2- use  crate :: hir:: def_id:: { DefId ,  DefIndex } ; 
2+ use  crate :: hir:: def_id:: { DefId ,  LocalDefId } ; 
33use  crate :: hir:: map:: DefPathHash ; 
44use  crate :: hir:: map:: definitions:: Definitions ; 
55use  crate :: ich:: { self ,  CachingSourceMapView ,  Fingerprint } ; 
@@ -139,8 +139,8 @@ impl<'a> StableHashingContext<'a> {
139139    } 
140140
141141    #[ inline]  
142-     pub  fn  local_def_path_hash ( & self ,  def_index :   DefIndex )  -> DefPathHash  { 
143-         self . definitions . def_path_hash ( def_index ) 
142+     pub  fn  local_def_path_hash ( & self ,  def_id :   LocalDefId )  -> DefPathHash  { 
143+         self . definitions . def_path_hash ( def_id . index ) 
144144    } 
145145
146146    #[ inline]  
@@ -238,7 +238,7 @@ impl<'a> HashStable<StableHashingContext<'a>> for hir::HirId {
238238                    local_id, 
239239                }  = * self ; 
240240
241-                 hcx. local_def_path_hash ( owner. index ) . hash_stable ( hcx,  hasher) ; 
241+                 hcx. local_def_path_hash ( owner) . hash_stable ( hcx,  hasher) ; 
242242                local_id. hash_stable ( hcx,  hasher) ; 
243243            } 
244244        } 
@@ -252,7 +252,7 @@ impl<'a> ToStableHashKey<StableHashingContext<'a>> for hir::HirId {
252252    fn  to_stable_hash_key ( & self , 
253253                          hcx :  & StableHashingContext < ' a > ) 
254254                          -> ( DefPathHash ,  hir:: ItemLocalId )  { 
255-         let  def_path_hash = hcx. local_def_path_hash ( self . owner . index ) ; 
255+         let  def_path_hash = hcx. local_def_path_hash ( self . owner ) ; 
256256        ( def_path_hash,  self . local_id ) 
257257    } 
258258} 
0 commit comments