@@ -2928,12 +2928,13 @@ pub enum WasiExecModel {
2928
2928
/// how the hash should be calculated when adding a new command-line argument.
2929
2929
pub ( crate ) mod dep_tracking {
2930
2930
use std:: collections:: BTreeMap ;
2931
- use std:: hash:: { DefaultHasher , Hash } ;
2931
+ use std:: hash:: Hash ;
2932
2932
use std:: num:: NonZero ;
2933
2933
use std:: path:: PathBuf ;
2934
2934
2935
2935
use rustc_abi:: Align ;
2936
2936
use rustc_data_structures:: fx:: FxIndexMap ;
2937
+ use rustc_data_structures:: stable_hasher:: StableHasher ;
2937
2938
use rustc_errors:: LanguageIdentifier ;
2938
2939
use rustc_feature:: UnstableFeatures ;
2939
2940
use rustc_hashes:: Hash64 ;
@@ -2960,7 +2961,7 @@ pub(crate) mod dep_tracking {
2960
2961
pub ( crate ) trait DepTrackingHash {
2961
2962
fn hash (
2962
2963
& self ,
2963
- hasher : & mut DefaultHasher ,
2964
+ hasher : & mut StableHasher ,
2964
2965
error_format : ErrorOutputType ,
2965
2966
for_crate_hash : bool ,
2966
2967
) ;
@@ -2969,7 +2970,7 @@ pub(crate) mod dep_tracking {
2969
2970
macro_rules! impl_dep_tracking_hash_via_hash {
2970
2971
( $( $t: ty) ,+ $( , ) ?) => { $(
2971
2972
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 ) {
2973
2974
Hash :: hash( self , hasher) ;
2974
2975
}
2975
2976
}
@@ -2979,7 +2980,7 @@ pub(crate) mod dep_tracking {
2979
2980
impl < T : DepTrackingHash > DepTrackingHash for Option < T > {
2980
2981
fn hash (
2981
2982
& self ,
2982
- hasher : & mut DefaultHasher ,
2983
+ hasher : & mut StableHasher ,
2983
2984
error_format : ErrorOutputType ,
2984
2985
for_crate_hash : bool ,
2985
2986
) {
@@ -3064,7 +3065,7 @@ pub(crate) mod dep_tracking {
3064
3065
{
3065
3066
fn hash (
3066
3067
& self ,
3067
- hasher : & mut DefaultHasher ,
3068
+ hasher : & mut StableHasher ,
3068
3069
error_format : ErrorOutputType ,
3069
3070
for_crate_hash : bool ,
3070
3071
) {
@@ -3083,7 +3084,7 @@ pub(crate) mod dep_tracking {
3083
3084
{
3084
3085
fn hash (
3085
3086
& self ,
3086
- hasher : & mut DefaultHasher ,
3087
+ hasher : & mut StableHasher ,
3087
3088
error_format : ErrorOutputType ,
3088
3089
for_crate_hash : bool ,
3089
3090
) {
@@ -3099,7 +3100,7 @@ pub(crate) mod dep_tracking {
3099
3100
impl < T : DepTrackingHash > DepTrackingHash for Vec < T > {
3100
3101
fn hash (
3101
3102
& self ,
3102
- hasher : & mut DefaultHasher ,
3103
+ hasher : & mut StableHasher ,
3103
3104
error_format : ErrorOutputType ,
3104
3105
for_crate_hash : bool ,
3105
3106
) {
@@ -3114,7 +3115,7 @@ pub(crate) mod dep_tracking {
3114
3115
impl < T : DepTrackingHash , V : DepTrackingHash > DepTrackingHash for FxIndexMap < T , V > {
3115
3116
fn hash (
3116
3117
& self ,
3117
- hasher : & mut DefaultHasher ,
3118
+ hasher : & mut StableHasher ,
3118
3119
error_format : ErrorOutputType ,
3119
3120
for_crate_hash : bool ,
3120
3121
) {
@@ -3129,7 +3130,7 @@ pub(crate) mod dep_tracking {
3129
3130
impl DepTrackingHash for OutputTypes {
3130
3131
fn hash (
3131
3132
& self ,
3132
- hasher : & mut DefaultHasher ,
3133
+ hasher : & mut StableHasher ,
3133
3134
error_format : ErrorOutputType ,
3134
3135
for_crate_hash : bool ,
3135
3136
) {
@@ -3146,7 +3147,7 @@ pub(crate) mod dep_tracking {
3146
3147
// This is a stable hash because BTreeMap is a sorted container
3147
3148
pub ( crate ) fn stable_hash (
3148
3149
sub_hashes : BTreeMap < & ' static str , & dyn DepTrackingHash > ,
3149
- hasher : & mut DefaultHasher ,
3150
+ hasher : & mut StableHasher ,
3150
3151
error_format : ErrorOutputType ,
3151
3152
for_crate_hash : bool ,
3152
3153
) {
0 commit comments