Skip to content

Commit

Permalink
old ocaml
Browse files Browse the repository at this point in the history
  • Loading branch information
hhugo committed Feb 1, 2023
1 parent 7af2c68 commit 88ba49e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions compiler/lib/stdlib.ml
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,12 @@ let int_num_bits =
module List = struct
include ListLabels

let rec equal ~eq a b =
match a, b with
| [], [] -> true
| x :: xs, y :: ys -> eq x y && equal ~eq xs ys
| [], _ :: _ | _ :: _, [] -> false

let rec find_map ~f = function
| [] -> None
| x :: l -> (
Expand Down

0 comments on commit 88ba49e

Please sign in to comment.