File tree 3 files changed +8
-6
lines changed
3 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -563,4 +563,6 @@ module With_subkind = struct
563
563
true
564
564
565
565
let erase_subkind t = { t with subkind = Anything }
566
+
567
+ let equal_ignoring_subkind t1 t2 = equal (erase_subkind t1) (erase_subkind t2)
566
568
end
Original file line number Diff line number Diff line change @@ -207,4 +207,6 @@ module With_subkind : sig
207
207
val erase_subkind : t -> t
208
208
209
209
include Container_types. S with type t := t
210
+
211
+ val equal_ignoring_subkind : t -> t -> bool
210
212
end
Original file line number Diff line number Diff line change @@ -107,12 +107,10 @@ let get_arg_types_by_use_id_for_invariant_params arity l =
107
107
List. fold_left
108
108
(fun arg_maps t ->
109
109
if not
110
- (Misc.Stdlib.List. is_prefix ~equal: Flambda_kind. equal
111
- (Flambda_arity. to_list arity
112
- |> List. map Flambda_kind.With_subkind. kind)
113
- ~of_:
114
- (Flambda_arity. to_list t.arity
115
- |> List. map Flambda_kind.With_subkind. kind))
110
+ (Misc.Stdlib.List. is_prefix
111
+ ~equal: Flambda_kind.With_subkind. equal_ignoring_subkind
112
+ (Flambda_arity. to_list arity)
113
+ ~of_: (Flambda_arity. to_list t.arity))
116
114
then
117
115
Misc. fatal_errorf
118
116
" Arity of invariant params@ (%a) is not a prefix of the arity of the \
You can’t perform that action at this time.
0 commit comments