@@ -875,7 +875,7 @@ fn diff_types<'tcx>(
875
875
876
876
match old {
877
877
// type aliases, consts and statics just need their type to be checked
878
- Def ( TyAlias , _ ) | Def ( Const , _ ) | Def ( Static , _) => {
878
+ Def ( TyAlias | Const | Static , _) => {
879
879
cmp_types (
880
880
changes,
881
881
id_mapping,
@@ -887,7 +887,7 @@ fn diff_types<'tcx>(
887
887
) ;
888
888
}
889
889
// functions and methods require us to compare their signatures, not types
890
- Def ( Fn , _ ) | Def ( AssocFn , _) => {
890
+ Def ( Fn | AssocFn , _) => {
891
891
let old_fn_sig = tcx. type_of ( old_def_id) . fn_sig ( tcx) ;
892
892
let new_fn_sig = tcx. type_of ( new_def_id) . fn_sig ( tcx) ;
893
893
@@ -902,7 +902,7 @@ fn diff_types<'tcx>(
902
902
) ;
903
903
}
904
904
// ADTs' types are compared field-wise
905
- Def ( Struct , _ ) | Def ( Enum , _ ) | Def ( Union , _) => {
905
+ Def ( Struct | Enum | Union , _) => {
906
906
if let Some ( children) = id_mapping. children_of ( old_def_id) {
907
907
for ( o_def_id, n_def_id) in children {
908
908
let o_ty = tcx. type_of ( o_def_id) ;
0 commit comments