@@ -2928,12 +2928,13 @@ pub enum WasiExecModel {
29282928/// how the hash should be calculated when adding a new command-line argument.
29292929pub ( crate ) mod dep_tracking {
29302930 use std:: collections:: BTreeMap ;
2931- use std:: hash:: { DefaultHasher , Hash } ;
2931+ use std:: hash:: Hash ;
29322932 use std:: num:: NonZero ;
29332933 use std:: path:: PathBuf ;
29342934
29352935 use rustc_abi:: Align ;
29362936 use rustc_data_structures:: fx:: FxIndexMap ;
2937+ use rustc_data_structures:: stable_hasher:: StableHasher ;
29372938 use rustc_errors:: LanguageIdentifier ;
29382939 use rustc_feature:: UnstableFeatures ;
29392940 use rustc_hashes:: Hash64 ;
@@ -2960,7 +2961,7 @@ pub(crate) mod dep_tracking {
29602961 pub ( crate ) trait DepTrackingHash {
29612962 fn hash (
29622963 & self ,
2963- hasher : & mut DefaultHasher ,
2964+ hasher : & mut StableHasher ,
29642965 error_format : ErrorOutputType ,
29652966 for_crate_hash : bool ,
29662967 ) ;
@@ -2969,7 +2970,7 @@ pub(crate) mod dep_tracking {
29692970 macro_rules! impl_dep_tracking_hash_via_hash {
29702971 ( $( $t: ty) ,+ $( , ) ?) => { $(
29712972 impl DepTrackingHash for $t {
2972- fn hash( & self , hasher: & mut DefaultHasher , _: ErrorOutputType , _for_crate_hash: bool ) {
2973+ fn hash( & self , hasher: & mut StableHasher , _: ErrorOutputType , _for_crate_hash: bool ) {
29732974 Hash :: hash( self , hasher) ;
29742975 }
29752976 }
@@ -2979,7 +2980,7 @@ pub(crate) mod dep_tracking {
29792980 impl < T : DepTrackingHash > DepTrackingHash for Option < T > {
29802981 fn hash (
29812982 & self ,
2982- hasher : & mut DefaultHasher ,
2983+ hasher : & mut StableHasher ,
29832984 error_format : ErrorOutputType ,
29842985 for_crate_hash : bool ,
29852986 ) {
@@ -3064,7 +3065,7 @@ pub(crate) mod dep_tracking {
30643065 {
30653066 fn hash (
30663067 & self ,
3067- hasher : & mut DefaultHasher ,
3068+ hasher : & mut StableHasher ,
30683069 error_format : ErrorOutputType ,
30693070 for_crate_hash : bool ,
30703071 ) {
@@ -3083,7 +3084,7 @@ pub(crate) mod dep_tracking {
30833084 {
30843085 fn hash (
30853086 & self ,
3086- hasher : & mut DefaultHasher ,
3087+ hasher : & mut StableHasher ,
30873088 error_format : ErrorOutputType ,
30883089 for_crate_hash : bool ,
30893090 ) {
@@ -3099,7 +3100,7 @@ pub(crate) mod dep_tracking {
30993100 impl < T : DepTrackingHash > DepTrackingHash for Vec < T > {
31003101 fn hash (
31013102 & self ,
3102- hasher : & mut DefaultHasher ,
3103+ hasher : & mut StableHasher ,
31033104 error_format : ErrorOutputType ,
31043105 for_crate_hash : bool ,
31053106 ) {
@@ -3114,7 +3115,7 @@ pub(crate) mod dep_tracking {
31143115 impl < T : DepTrackingHash , V : DepTrackingHash > DepTrackingHash for FxIndexMap < T , V > {
31153116 fn hash (
31163117 & self ,
3117- hasher : & mut DefaultHasher ,
3118+ hasher : & mut StableHasher ,
31183119 error_format : ErrorOutputType ,
31193120 for_crate_hash : bool ,
31203121 ) {
@@ -3129,7 +3130,7 @@ pub(crate) mod dep_tracking {
31293130 impl DepTrackingHash for OutputTypes {
31303131 fn hash (
31313132 & self ,
3132- hasher : & mut DefaultHasher ,
3133+ hasher : & mut StableHasher ,
31333134 error_format : ErrorOutputType ,
31343135 for_crate_hash : bool ,
31353136 ) {
@@ -3146,7 +3147,7 @@ pub(crate) mod dep_tracking {
31463147 // This is a stable hash because BTreeMap is a sorted container
31473148 pub ( crate ) fn stable_hash (
31483149 sub_hashes : BTreeMap < & ' static str , & dyn DepTrackingHash > ,
3149- hasher : & mut DefaultHasher ,
3150+ hasher : & mut StableHasher ,
31503151 error_format : ErrorOutputType ,
31513152 for_crate_hash : bool ,
31523153 ) {
0 commit comments