@@ -734,6 +734,9 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
734
734
self . hash_name ( i. ident . name ) ;
735
735
}
736
736
} ,
737
+ ExprKind :: Array ( v) => {
738
+ self . hash_exprs ( v) ;
739
+ } ,
737
740
ExprKind :: Assign ( l, r, _) => {
738
741
self . hash_expr ( l) ;
739
742
self . hash_expr ( r) ;
@@ -743,6 +746,9 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
743
746
self . hash_expr ( l) ;
744
747
self . hash_expr ( r) ;
745
748
} ,
749
+ ExprKind :: Become ( f) => {
750
+ self . hash_expr ( f) ;
751
+ } ,
746
752
ExprKind :: Block ( b, _) => {
747
753
self . hash_block ( b) ;
748
754
} ,
@@ -759,9 +765,6 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
759
765
self . hash_expr ( j) ;
760
766
}
761
767
} ,
762
- ExprKind :: DropTemps ( e) | ExprKind :: Yield ( e, _) => {
763
- self . hash_expr ( e) ;
764
- } ,
765
768
ExprKind :: Call ( fun, args) => {
766
769
self . hash_expr ( fun) ;
767
770
self . hash_exprs ( args) ;
@@ -777,6 +780,12 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
777
780
// closures inherit TypeckResults
778
781
self . hash_expr ( self . cx . tcx . hir ( ) . body ( body) . value ) ;
779
782
} ,
783
+ ExprKind :: ConstBlock ( ref l_id) => {
784
+ self . hash_body ( l_id. body ) ;
785
+ } ,
786
+ ExprKind :: DropTemps ( e) | ExprKind :: Yield ( e, _) => {
787
+ self . hash_expr ( e) ;
788
+ } ,
780
789
ExprKind :: Field ( e, ref f) => {
781
790
self . hash_expr ( e) ;
782
791
self . hash_name ( f. name ) ;
@@ -838,20 +847,13 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
838
847
}
839
848
}
840
849
} ,
841
- ExprKind :: OffsetOf ( container, fields) => {
842
- self . hash_ty ( container) ;
843
- for field in fields {
844
- self . hash_name ( field. name ) ;
845
- }
846
- } ,
847
850
ExprKind :: Let ( Let { pat, init, ty, .. } ) => {
848
851
self . hash_expr ( init) ;
849
852
if let Some ( ty) = ty {
850
853
self . hash_ty ( ty) ;
851
854
}
852
855
self . hash_pat ( pat) ;
853
856
} ,
854
- ExprKind :: Err ( _) => { } ,
855
857
ExprKind :: Lit ( l) => {
856
858
l. node . hash ( & mut self . s ) ;
857
859
} ,
@@ -886,8 +888,14 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
886
888
self . hash_expr ( receiver) ;
887
889
self . hash_exprs ( args) ;
888
890
} ,
889
- ExprKind :: ConstBlock ( ref l_id) => {
890
- self . hash_body ( l_id. body ) ;
891
+ ExprKind :: OffsetOf ( container, fields) => {
892
+ self . hash_ty ( container) ;
893
+ for field in fields {
894
+ self . hash_name ( field. name ) ;
895
+ }
896
+ } ,
897
+ ExprKind :: Path ( ref qpath) => {
898
+ self . hash_qpath ( qpath) ;
891
899
} ,
892
900
ExprKind :: Repeat ( e, len) => {
893
901
self . hash_expr ( e) ;
@@ -898,12 +906,6 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
898
906
self . hash_expr ( e) ;
899
907
}
900
908
} ,
901
- ExprKind :: Become ( f) => {
902
- self . hash_expr ( f) ;
903
- } ,
904
- ExprKind :: Path ( ref qpath) => {
905
- self . hash_qpath ( qpath) ;
906
- } ,
907
909
ExprKind :: Struct ( path, fields, ref expr) => {
908
910
self . hash_qpath ( path) ;
909
911
@@ -919,13 +921,11 @@ impl<'a, 'tcx> SpanlessHash<'a, 'tcx> {
919
921
ExprKind :: Tup ( tup) => {
920
922
self . hash_exprs ( tup) ;
921
923
} ,
922
- ExprKind :: Array ( v) => {
923
- self . hash_exprs ( v) ;
924
- } ,
925
924
ExprKind :: Unary ( lop, le) => {
926
925
std:: mem:: discriminant ( & lop) . hash ( & mut self . s ) ;
927
926
self . hash_expr ( le) ;
928
927
} ,
928
+ ExprKind :: Err ( _) => { } ,
929
929
}
930
930
}
931
931
0 commit comments