@@ -25,7 +25,7 @@ use ty;
25
25
use mir;
26
26
27
27
impl < ' a , ' gcx , T > HashStable < StableHashingContext < ' a > >
28
- for & ' gcx ty:: Slice < T >
28
+ for & ' gcx ty:: List < T >
29
29
where T : HashStable < StableHashingContext < ' a > > {
30
30
fn hash_stable < W : StableHasherResult > ( & self ,
31
31
hcx : & mut StableHashingContext < ' a > ,
@@ -53,7 +53,7 @@ for &'gcx ty::Slice<T>
53
53
}
54
54
}
55
55
56
- impl < ' a , ' gcx , T > ToStableHashKey < StableHashingContext < ' a > > for & ' gcx ty:: Slice < T >
56
+ impl < ' a , ' gcx , T > ToStableHashKey < StableHashingContext < ' a > > for & ' gcx ty:: List < T >
57
57
where T : HashStable < StableHashingContext < ' a > >
58
58
{
59
59
type KeyType = Fingerprint ;
@@ -797,90 +797,90 @@ impl_stable_hash_for!(enum ty::BoundRegion {
797
797
} ) ;
798
798
799
799
impl < ' a , ' gcx > HashStable < StableHashingContext < ' a > >
800
- for ty:: TypeVariants < ' gcx >
800
+ for ty:: TyKind < ' gcx >
801
801
{
802
802
fn hash_stable < W : StableHasherResult > ( & self ,
803
803
hcx : & mut StableHashingContext < ' a > ,
804
804
hasher : & mut StableHasher < W > ) {
805
- use ty:: TypeVariants :: * ;
805
+ use ty:: TyKind :: * ;
806
806
807
807
mem:: discriminant ( self ) . hash_stable ( hcx, hasher) ;
808
808
match * self {
809
- TyBool |
810
- TyChar |
811
- TyStr |
812
- TyError |
813
- TyNever => {
809
+ Bool |
810
+ Char |
811
+ Str |
812
+ Error |
813
+ Never => {
814
814
// Nothing more to hash.
815
815
}
816
- TyInt ( int_ty) => {
816
+ Int ( int_ty) => {
817
817
int_ty. hash_stable ( hcx, hasher) ;
818
818
}
819
- TyUint ( uint_ty) => {
819
+ Uint ( uint_ty) => {
820
820
uint_ty. hash_stable ( hcx, hasher) ;
821
821
}
822
- TyFloat ( float_ty) => {
822
+ Float ( float_ty) => {
823
823
float_ty. hash_stable ( hcx, hasher) ;
824
824
}
825
- TyAdt ( adt_def, substs) => {
825
+ Adt ( adt_def, substs) => {
826
826
adt_def. hash_stable ( hcx, hasher) ;
827
827
substs. hash_stable ( hcx, hasher) ;
828
828
}
829
- TyArray ( inner_ty, len) => {
829
+ Array ( inner_ty, len) => {
830
830
inner_ty. hash_stable ( hcx, hasher) ;
831
831
len. hash_stable ( hcx, hasher) ;
832
832
}
833
- TySlice ( inner_ty) => {
833
+ Slice ( inner_ty) => {
834
834
inner_ty. hash_stable ( hcx, hasher) ;
835
835
}
836
- TyRawPtr ( pointee_ty) => {
836
+ RawPtr ( pointee_ty) => {
837
837
pointee_ty. hash_stable ( hcx, hasher) ;
838
838
}
839
- TyRef ( region, pointee_ty, mutbl) => {
839
+ Ref ( region, pointee_ty, mutbl) => {
840
840
region. hash_stable ( hcx, hasher) ;
841
841
pointee_ty. hash_stable ( hcx, hasher) ;
842
842
mutbl. hash_stable ( hcx, hasher) ;
843
843
}
844
- TyFnDef ( def_id, substs) => {
844
+ FnDef ( def_id, substs) => {
845
845
def_id. hash_stable ( hcx, hasher) ;
846
846
substs. hash_stable ( hcx, hasher) ;
847
847
}
848
- TyFnPtr ( ref sig) => {
848
+ FnPtr ( ref sig) => {
849
849
sig. hash_stable ( hcx, hasher) ;
850
850
}
851
- TyDynamic ( ref existential_predicates, region) => {
851
+ Dynamic ( ref existential_predicates, region) => {
852
852
existential_predicates. hash_stable ( hcx, hasher) ;
853
853
region. hash_stable ( hcx, hasher) ;
854
854
}
855
- TyClosure ( def_id, closure_substs) => {
855
+ Closure ( def_id, closure_substs) => {
856
856
def_id. hash_stable ( hcx, hasher) ;
857
857
closure_substs. hash_stable ( hcx, hasher) ;
858
858
}
859
- TyGenerator ( def_id, generator_substs, movability) => {
859
+ Generator ( def_id, generator_substs, movability) => {
860
860
def_id. hash_stable ( hcx, hasher) ;
861
861
generator_substs. hash_stable ( hcx, hasher) ;
862
862
movability. hash_stable ( hcx, hasher) ;
863
863
}
864
- TyGeneratorWitness ( types) => {
864
+ GeneratorWitness ( types) => {
865
865
types. hash_stable ( hcx, hasher)
866
866
}
867
- TyTuple ( inner_tys) => {
867
+ Tuple ( inner_tys) => {
868
868
inner_tys. hash_stable ( hcx, hasher) ;
869
869
}
870
- TyProjection ( ref projection_ty) => {
870
+ Projection ( ref projection_ty) => {
871
871
projection_ty. hash_stable ( hcx, hasher) ;
872
872
}
873
- TyAnon ( def_id, substs) => {
873
+ Anon ( def_id, substs) => {
874
874
def_id. hash_stable ( hcx, hasher) ;
875
875
substs. hash_stable ( hcx, hasher) ;
876
876
}
877
- TyParam ( param_ty) => {
877
+ Param ( param_ty) => {
878
878
param_ty. hash_stable ( hcx, hasher) ;
879
879
}
880
- TyForeign ( def_id) => {
880
+ Foreign ( def_id) => {
881
881
def_id. hash_stable ( hcx, hasher) ;
882
882
}
883
- TyInfer ( infer_ty) => {
883
+ Infer ( infer_ty) => {
884
884
infer_ty. hash_stable ( hcx, hasher) ;
885
885
}
886
886
}
@@ -905,7 +905,7 @@ for ty::TyVid
905
905
_hasher : & mut StableHasher < W > ) {
906
906
// TyVid values are confined to an inference context and hence
907
907
// should not be hashed.
908
- bug ! ( "ty::TypeVariants ::hash_stable() - can't hash a TyVid {:?}." , * self )
908
+ bug ! ( "ty::TyKind ::hash_stable() - can't hash a TyVid {:?}." , * self )
909
909
}
910
910
}
911
911
@@ -917,7 +917,7 @@ for ty::IntVid
917
917
_hasher : & mut StableHasher < W > ) {
918
918
// IntVid values are confined to an inference context and hence
919
919
// should not be hashed.
920
- bug ! ( "ty::TypeVariants ::hash_stable() - can't hash an IntVid {:?}." , * self )
920
+ bug ! ( "ty::TyKind ::hash_stable() - can't hash an IntVid {:?}." , * self )
921
921
}
922
922
}
923
923
@@ -929,7 +929,7 @@ for ty::FloatVid
929
929
_hasher : & mut StableHasher < W > ) {
930
930
// FloatVid values are confined to an inference context and hence
931
931
// should not be hashed.
932
- bug ! ( "ty::TypeVariants ::hash_stable() - can't hash a FloatVid {:?}." , * self )
932
+ bug ! ( "ty::TyKind ::hash_stable() - can't hash a FloatVid {:?}." , * self )
933
933
}
934
934
}
935
935
0 commit comments