@@ -229,7 +229,7 @@ let expr_deps blocks st x e =
229229 dependencies right now. This speeds up the analysis
230230 significantly. *)
231231 match st.defs.(Var. idx f) with
232- | Expr (Closure (params , _ , _ )) when List. length args = List. length params ->
232+ | Expr (Closure (params , _ , _ )) when List. compare_lengths args params = 0 ->
233233 Hashtbl. add st.applied_functions (x, f) () ;
234234 add_to_list st.function_call_sites f x;
235235 if st.fast
@@ -510,7 +510,7 @@ let propagate st ~update approx x =
510510 (fun g ->
511511 match st.defs.(Var. idx g) with
512512 | Expr (Closure (params, _, _))
513- when List. length args = List. length params ->
513+ when List. compare_lengths args params = 0 ->
514514 if not (Hashtbl. mem st.applied_functions (x, g))
515515 then (
516516 Hashtbl. add st.applied_functions (x, g) () ;
@@ -729,7 +729,7 @@ let exact_call info f n =
729729 Var.Set. for_all
730730 (fun g ->
731731 match info.info_defs.(Var. idx g) with
732- | Expr (Closure (params , _ , _ )) -> List. length params = n
732+ | Expr (Closure (params , _ , _ )) -> List. compare_length_with params ~len: n = 0
733733 | Expr (Block _ ) -> true
734734 | Expr _ | Phi _ -> assert false )
735735 known
0 commit comments