-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
51 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,10 +22,6 @@ | |
(depends | ||
(ocaml | ||
(>= 5.2)) | ||
(base | ||
(and | ||
(>= v0.17) | ||
(< v0.18))) | ||
(bisect_ppx | ||
(and | ||
:dev | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
let phys_equal = ( == ) | ||
|
||
module Array = struct | ||
include ArrayLabels | ||
|
||
let for_alli = | ||
let rec loop t ~f i = | ||
if i = length t then true else if f i t.(i) then loop t ~f (i + 1) else false | ||
in | ||
fun t ~f -> loop t ~f 0 | ||
;; | ||
end | ||
|
||
module List = ListLabels | ||
|
||
module Ordering = struct | ||
type t = | ||
| Equal | ||
| Less | ||
| Greater | ||
|
||
let of_int i = if i < 0 then Less else if i = 0 then Equal else Greater | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
val phys_equal : 'a -> 'a -> bool | ||
|
||
module Array : sig | ||
include module type of ArrayLabels | ||
|
||
val for_alli : 'a array -> f:(int -> 'a -> bool) -> bool | ||
end | ||
|
||
module List : sig | ||
include module type of ListLabels | ||
end | ||
|
||
module Ordering : sig | ||
type t = | ||
| Equal | ||
| Less | ||
| Greater | ||
|
||
val of_int : int -> t | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters