sig
type ('a, 'b) t = ('a, 'b) BatArray.Cap.t
constraint 'b = [< `Read | `Write ]
external length : ('a, [< `Read | `Write ]) t -> int = "%array_length"
external get : ('a, [< `Read | `Write > `Read ]) t -> int -> 'a
= "%array_safe_get"
external set : ('a, [< `Read | `Write > `Write ]) t -> int -> 'a -> unit
= "%array_safe_set"
external make : int -> 'a -> ('a, [< `Read | `Write ]) t = "caml_make_vect"
external create : int -> 'a -> ('a, [< `Read | `Write ]) t
= "caml_make_vect"
external make_float : int -> (float, [< `Read | `Write ]) t
= "caml_make_float_vect"
external of_array : 'a array -> ('a, [< `Read | `Write ]) t = "%identity"
external to_array : ('a, [ `Read | `Write ]) t -> 'a array = "%identity"
external read_only :
('a, [< `Read | `Write > `Read ]) t -> ('a, [ `Read ]) t = "%identity"
external write_only :
('a, [< `Read | `Write > `Write ]) t -> ('a, [ `Write ]) t = "%identity"
val init : int -> (int -> 'a) -> ('a, [< `Read | `Write ]) t
val make_matrix :
int -> int -> 'a -> (('a, [< `Read | `Write ]) t, [< `Read | `Write ]) t
val create_matrix :
int -> int -> 'a -> (('a, [< `Read | `Write ]) t, [< `Read | `Write ]) t
val iter : ('a -> unit) -> ('a, [< `Read | `Write > `Read ]) t -> unit
val map :
('a -> 'b) ->
('a, [< `Read | `Write > `Read ]) t -> ('b, [< `Read | `Write ]) t
val iteri :
(int -> 'a -> unit) -> ('a, [< `Read | `Write > `Read ]) t -> unit
val mapi :
(int -> 'a -> 'b) ->
('a, [< `Read | `Write > `Read ]) t -> ('b, [< `Read | `Write ]) t
val modify : ('a -> 'a) -> ('a, [ `Read | `Write ]) t -> unit
val modifyi : (int -> 'a -> 'a) -> ('a, [ `Read | `Write ]) t -> unit
val fold_left :
('a -> 'b -> 'a) -> 'a -> ('b, [< `Read | `Write > `Read ]) t -> 'a
val fold :
('a -> 'b -> 'a) -> 'a -> ('b, [< `Read | `Write > `Read ]) t -> 'a
val fold_right :
('b -> 'a -> 'a) -> ('b, [< `Read | `Write > `Read ]) t -> 'a -> 'a
val fold_while :
('acc -> 'a -> bool) ->
('acc -> 'a -> 'acc) ->
'acc -> ('a, [< `Read | `Write > `Read ]) t -> 'acc * int
val iter2 :
('a -> 'b -> unit) ->
('a, [< `Read | `Write > `Read ]) t ->
('b, [< `Read | `Write > `Read ]) t -> unit
val iter2i :
(int -> 'a -> 'b -> unit) ->
('a, [< `Read | `Write > `Read ]) t ->
('b, [< `Read | `Write > `Read ]) t -> unit
val for_all : ('a -> bool) -> ('a, [< `Read | `Write > `Read ]) t -> bool
val exists : ('a -> bool) -> ('a, [< `Read | `Write > `Read ]) t -> bool
val find_opt :
('a -> bool) -> ('a, [< `Read | `Write > `Read ]) t -> 'a option
val find_map :
('a -> 'b option) -> ('a, [< `Read | `Write > `Read ]) t -> 'b option
val mem : 'a -> ('a, [< `Read | `Write > `Read ]) t -> bool
val memq : 'a -> ('a, [< `Read | `Write > `Read ]) t -> bool
val filter :
('a -> bool) ->
('a, [< `Read | `Write > `Read ]) t -> ('a, [< `Read | `Write ]) t
val filter_map :
('a -> 'b option) ->
('a, [< `Read | `Write > `Read ]) t -> ('b, [< `Read | `Write ]) t
val count_matching :
('a -> bool) -> ('a, [< `Read | `Write > `Read ]) t -> int
val find_all :
('a -> bool) ->
('a, [< `Read | `Write > `Read ]) t -> ('a, [< `Read | `Write ]) t
val partition :
('a -> bool) ->
('a, [< `Read | `Write > `Read ]) t ->
('a, [< `Read | `Write ]) t * ('a, [< `Read | `Write ]) t
val rev :
('a, [< `Read | `Write > `Read ]) t -> ('a, [< `Read | `Write ]) t
val rev_in_place : ('a, [ `Read | `Write ]) t -> unit
val append :
('a, [< `Read | `Write > `Read ]) t ->
('a, [< `Read | `Write > `Read ]) t -> ('a, [< `Read | `Write ]) t
val concat :
('a, [< `Read | `Write > `Read ]) t list -> ('a, [< `Read | `Write ]) t
val sub :
('a, [< `Read | `Write > `Read ]) t ->
int -> int -> ('a, [< `Read | `Write ]) t
val copy : ('a, [< `Read | `Write > `Read ]) t -> 'a array
val fill : ('a, [< `Read | `Write > `Write ]) t -> int -> int -> 'a -> unit
val blit :
('a, [< `Read | `Write > `Read ]) t ->
int -> ('a, [< `Read | `Write > `Write ]) t -> int -> int -> unit
val enum : ('a, [< `Read | `Write > `Read ]) t -> 'a BatEnum.t
val of_enum : 'a BatEnum.t -> ('a, [< `Read | `Write ]) t
val backwards : ('a, [< `Read | `Write > `Read ]) t -> 'a BatEnum.t
val of_backwards : 'a BatEnum.t -> ('a, [< `Read | `Write ]) t
val to_list : ('a, [< `Read | `Write > `Read ]) t -> 'a list
val split :
('a * 'b, [< `Read | `Write > `Read ]) t ->
('a, [< `Read | `Write ]) t * ('b, [< `Read | `Write ]) t
val combine :
('a, [< `Read | `Write > `Read ]) t ->
('b, [< `Read | `Write > `Read ]) t ->
('a * 'b, [< `Read | `Write > `Read ]) t
val pivot_split :
'a BatOrd.ord -> ('a, [< `Read | `Write > `Read ]) t -> 'a -> int * int
val of_list : 'a list -> ('a, [< `Read | `Write ]) t
val sort : ('a -> 'a -> int) -> ('a, [ `Read | `Write ]) t -> unit
val stable_sort : ('a -> 'a -> int) -> ('a, [ `Read | `Write ]) t -> unit
val fast_sort : ('a -> 'a -> int) -> ('a, [ `Read | `Write ]) t -> unit
val print :
?first:string ->
?last:string ->
?sep:string ->
('a BatIO.output -> 'b -> unit) ->
'a BatIO.output -> ('b, [< `Read | `Write > `Read ]) t -> unit
val compare :
'a BatOrd.comp -> ('a, [< `Read | `Write > `Read ]) t BatOrd.comp
val ord : 'a BatOrd.ord -> ('a, [< `Read | `Write > `Read ]) t BatOrd.ord
val equal : 'a BatOrd.eq -> ('a, [< `Read | `Write > `Read ]) t BatOrd.eq
module Exceptionless = BatArray.Cap.Exceptionless
module Labels = BatArray.Cap.Labels
external unsafe_get : ('a, [< `Read | `Write > `Read ]) t -> int -> 'a
= "%array_unsafe_get"
external unsafe_set :
('a, [< `Read | `Write > `Write ]) t -> int -> 'a -> unit
= "%array_unsafe_set"
val find :
('a -> bool) ->
('a, [< `Read | `Write > `Read ]) BatArray.Cap.t -> 'a option
val findi :
('a -> bool) ->
('a, [< `Read | `Write > `Read ]) BatArray.Cap.t -> int option
end