sig
type 'a t
exception Out_of_bounds
val max_length : int
val empty : 'a BatVect.t
val singleton : 'a -> 'a BatVect.t
val of_array : 'a array -> 'a BatVect.t
val to_array : 'a BatVect.t -> 'a array
val to_list : 'a BatVect.t -> 'a list
val of_list : 'a list -> 'a BatVect.t
val make : int -> 'a -> 'a BatVect.t
val init : int -> (int -> 'a) -> 'a BatVect.t
val is_empty : 'a BatVect.t -> bool
val height : 'a BatVect.t -> int
val length : 'a BatVect.t -> int
val balance : 'a BatVect.t -> 'a BatVect.t
val concat : 'a BatVect.t -> 'a BatVect.t -> 'a BatVect.t
val append : 'a -> 'a BatVect.t -> 'a BatVect.t
val prepend : 'a -> 'a BatVect.t -> 'a BatVect.t
val get : 'a BatVect.t -> int -> 'a
val at : 'a BatVect.t -> int -> 'a
val set : 'a BatVect.t -> int -> 'a -> 'a BatVect.t
val modify : 'a BatVect.t -> int -> ('a -> 'a) -> 'a BatVect.t
val destructive_set : 'a BatVect.t -> int -> 'a -> unit
val sub : 'a BatVect.t -> int -> int -> 'a BatVect.t
val insert : int -> 'a BatVect.t -> 'a BatVect.t -> 'a BatVect.t
val remove : int -> int -> 'a BatVect.t -> 'a BatVect.t
val enum : 'a BatVect.t -> 'a BatEnum.t
val of_enum : 'a BatEnum.t -> 'a BatVect.t
val backwards : 'a BatVect.t -> 'a BatEnum.t
val of_backwards : 'a BatEnum.t -> 'a BatVect.t
val iter : ('a -> unit) -> 'a BatVect.t -> unit
val iteri : (int -> 'a -> unit) -> 'a BatVect.t -> unit
val rangeiter : ('a -> unit) -> int -> int -> 'a BatVect.t -> unit
val fold_left : ('b -> 'a -> 'b) -> 'b -> 'a BatVect.t -> 'b
val fold : ('b -> 'a -> 'b) -> 'b -> 'a BatVect.t -> 'b
val reduce : ('a -> 'a -> 'a) -> 'a BatVect.t -> 'a
val fold_right : ('a -> 'b -> 'b) -> 'a BatVect.t -> 'b -> 'b
val foldi : (int -> 'b -> 'a -> 'b) -> 'b -> 'a BatVect.t -> 'b
val map : ('a -> 'b) -> 'a BatVect.t -> 'b BatVect.t
val mapi : (int -> 'a -> 'b) -> 'a BatVect.t -> 'b BatVect.t
val for_all : ('a -> bool) -> 'a BatVect.t -> bool
val exists : ('a -> bool) -> 'a BatVect.t -> bool
val find : ('a -> bool) -> 'a BatVect.t -> 'a
val find_opt : ('a -> bool) -> 'a BatVect.t -> 'a option
val mem : 'a -> 'a BatVect.t -> bool
val memq : 'a -> 'a BatVect.t -> bool
val findi : ('a -> bool) -> 'a BatVect.t -> int
val filter : ('a -> bool) -> 'a BatVect.t -> 'a BatVect.t
val filter_map : ('a -> 'b option) -> 'a BatVect.t -> 'b BatVect.t
val find_all : ('a -> bool) -> 'a BatVect.t -> 'a BatVect.t
val partition : ('a -> bool) -> 'a BatVect.t -> 'a BatVect.t * 'a BatVect.t
val first : 'a BatVect.t -> 'a
val last : 'a BatVect.t -> 'a
val shift : 'a BatVect.t -> 'a * 'a BatVect.t
val pop : 'a BatVect.t -> 'a * 'a BatVect.t
val print :
?first:string ->
?last:string ->
?sep:string ->
('a BatInnerIO.output -> 'b -> unit) ->
'a BatInnerIO.output -> 'b BatVect.t -> unit
val compare : 'a BatOrd.comp -> 'a BatVect.t BatOrd.comp
val equal : 'a BatOrd.eq -> 'a BatVect.t BatOrd.eq
val ord : 'a BatOrd.ord -> 'a BatVect.t BatOrd.ord
val invariants : 'a BatVect.t -> unit
module Labels :
sig
val init : int -> f:(int -> 'a) -> 'a BatVect.t
val get : 'a BatVect.t -> n:int -> 'a
val at : 'a BatVect.t -> n:int -> 'a
val set : 'a BatVect.t -> n:int -> elem:'a -> 'a BatVect.t
val modify : 'a BatVect.t -> n:int -> f:('a -> 'a) -> 'a BatVect.t
val destructive_set : 'a BatVect.t -> n:int -> elem:'a -> unit
val sub : 'a BatVect.t -> m:int -> n:int -> 'a BatVect.t
val insert : n:int -> sub:'a BatVect.t -> 'a BatVect.t -> 'a BatVect.t
val remove : m:int -> n:int -> 'a BatVect.t -> 'a BatVect.t
val iter : f:('a -> unit) -> 'a BatVect.t -> unit
val iteri : f:(int -> 'a -> unit) -> 'a BatVect.t -> unit
val rangeiter :
f:('a -> unit) -> m:int -> n:int -> 'a BatVect.t -> unit
val fold_left : f:('b -> 'a -> 'b) -> init:'b -> 'a BatVect.t -> 'b
val fold : f:('b -> 'a -> 'b) -> init:'b -> 'a BatVect.t -> 'b
val reduce : f:('a -> 'a -> 'a) -> 'a BatVect.t -> 'a
val fold_right : f:('a -> 'b -> 'b) -> 'a BatVect.t -> init:'b -> 'b
val foldi : f:(int -> 'b -> 'a -> 'b) -> init:'b -> 'a BatVect.t -> 'b
val map : f:('a -> 'b) -> 'a BatVect.t -> 'b BatVect.t
val mapi : f:(int -> 'a -> 'b) -> 'a BatVect.t -> 'b BatVect.t
val for_all : f:('a -> bool) -> 'a BatVect.t -> bool
val exists : f:('a -> bool) -> 'a BatVect.t -> bool
val find : f:('a -> bool) -> 'a BatVect.t -> 'a
val mem : elem:'a -> 'a BatVect.t -> bool
val memq : elem:'a -> 'a BatVect.t -> bool
val findi : f:('a -> bool) -> 'a BatVect.t -> int
val filter : f:('a -> bool) -> 'a BatVect.t -> 'a BatVect.t
val filter_map : f:('a -> 'b option) -> 'a BatVect.t -> 'b BatVect.t
val find_all : f:('a -> bool) -> 'a BatVect.t -> 'a BatVect.t
val partition :
f:('a -> bool) -> 'a BatVect.t -> 'a BatVect.t * 'a BatVect.t
end
module type RANDOMACCESS =
sig
type 'a t
val empty : 'a BatVect.RANDOMACCESS.t
val get : 'a BatVect.RANDOMACCESS.t -> int -> 'a
val unsafe_get : 'a BatVect.RANDOMACCESS.t -> int -> 'a
val set : 'a BatVect.RANDOMACCESS.t -> int -> 'a -> unit
val unsafe_set : 'a BatVect.RANDOMACCESS.t -> int -> 'a -> unit
val append :
'a BatVect.RANDOMACCESS.t ->
'a BatVect.RANDOMACCESS.t -> 'a BatVect.RANDOMACCESS.t
val concat :
'a BatVect.RANDOMACCESS.t list -> 'a BatVect.RANDOMACCESS.t
val length : 'a BatVect.RANDOMACCESS.t -> int
val copy : 'a BatVect.RANDOMACCESS.t -> 'a BatVect.RANDOMACCESS.t
val sub :
'a BatVect.RANDOMACCESS.t -> int -> int -> 'a BatVect.RANDOMACCESS.t
val make : int -> 'a -> 'a BatVect.RANDOMACCESS.t
val iter : ('a -> unit) -> 'a BatVect.RANDOMACCESS.t -> unit
val map :
('a -> 'b) -> 'a BatVect.RANDOMACCESS.t -> 'b BatVect.RANDOMACCESS.t
val fold_right :
('a -> 'b -> 'b) -> 'a BatVect.RANDOMACCESS.t -> 'b -> 'b
val enum : 'a BatVect.RANDOMACCESS.t -> 'a BatEnum.t
val backwards : 'a BatVect.RANDOMACCESS.t -> 'a BatEnum.t
val of_enum : 'a BatEnum.t -> 'a BatVect.RANDOMACCESS.t
val of_backwards : 'a BatEnum.t -> 'a BatVect.RANDOMACCESS.t
end
module Make :
functor (R : RANDOMACCESS)
(PARAM : sig val max_height : int val leaf_size : int end) ->
sig
type 'a t
exception Out_of_bounds
val max_length : int
val empty : 'a BatVect.Make.t
val singleton : 'a -> 'a BatVect.Make.t
val of_container : 'a R.t -> 'a BatVect.Make.t
val to_container : 'a BatVect.Make.t -> 'a R.t
val of_array : 'a array -> 'a BatVect.Make.t
val to_array : 'a BatVect.Make.t -> 'a array
val to_list : 'a BatVect.Make.t -> 'a list
val of_list : 'a list -> 'a BatVect.Make.t
val make : int -> 'a -> 'a BatVect.Make.t
val init : int -> (int -> 'a) -> 'a BatVect.Make.t
val is_empty : 'a BatVect.Make.t -> bool
val height : 'a BatVect.Make.t -> int
val length : 'a BatVect.Make.t -> int
val balance : 'a BatVect.Make.t -> 'a BatVect.Make.t
val concat :
'a BatVect.Make.t -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val append : 'a -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val prepend : 'a -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val get : 'a BatVect.Make.t -> int -> 'a
val at : 'a BatVect.Make.t -> int -> 'a
val set : 'a BatVect.Make.t -> int -> 'a -> 'a BatVect.Make.t
val modify :
'a BatVect.Make.t -> int -> ('a -> 'a) -> 'a BatVect.Make.t
val destructive_set : 'a BatVect.Make.t -> int -> 'a -> unit
val sub : 'a BatVect.Make.t -> int -> int -> 'a BatVect.Make.t
val insert :
int -> 'a BatVect.Make.t -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val remove : int -> int -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val enum : 'a BatVect.Make.t -> 'a BatEnum.t
val of_enum : 'a BatEnum.t -> 'a BatVect.Make.t
val backwards : 'a BatVect.Make.t -> 'a BatEnum.t
val of_backwards : 'a BatEnum.t -> 'a BatVect.Make.t
val iter : ('a -> unit) -> 'a BatVect.Make.t -> unit
val iteri : (int -> 'a -> unit) -> 'a BatVect.Make.t -> unit
val rangeiter :
('a -> unit) -> int -> int -> 'a BatVect.Make.t -> unit
val fold_left : ('b -> 'a -> 'b) -> 'b -> 'a BatVect.Make.t -> 'b
val fold : ('b -> 'a -> 'b) -> 'b -> 'a BatVect.Make.t -> 'b
val reduce : ('a -> 'a -> 'a) -> 'a BatVect.Make.t -> 'a
val fold_right : ('a -> 'b -> 'b) -> 'a BatVect.Make.t -> 'b -> 'b
val foldi : (int -> 'b -> 'a -> 'b) -> 'b -> 'a BatVect.Make.t -> 'b
val map : ('a -> 'b) -> 'a BatVect.Make.t -> 'b BatVect.Make.t
val mapi :
(int -> 'a -> 'b) -> 'a BatVect.Make.t -> 'b BatVect.Make.t
val for_all : ('a -> bool) -> 'a BatVect.Make.t -> bool
val exists : ('a -> bool) -> 'a BatVect.Make.t -> bool
val find : ('a -> bool) -> 'a BatVect.Make.t -> 'a
val find_opt : ('a -> bool) -> 'a BatVect.Make.t -> 'a option
val mem : 'a -> 'a BatVect.Make.t -> bool
val memq : 'a -> 'a BatVect.Make.t -> bool
val findi : ('a -> bool) -> 'a BatVect.Make.t -> int
val filter : ('a -> bool) -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val filter_map :
('a -> 'b option) -> 'a BatVect.Make.t -> 'b BatVect.Make.t
val find_all : ('a -> bool) -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val partition :
('a -> bool) ->
'a BatVect.Make.t -> 'a BatVect.Make.t * 'a BatVect.Make.t
val first : 'a BatVect.Make.t -> 'a
val last : 'a BatVect.Make.t -> 'a
val shift : 'a BatVect.Make.t -> 'a * 'a BatVect.Make.t
val pop : 'a BatVect.Make.t -> 'a * 'a BatVect.Make.t
module Labels :
sig
val init : int -> f:(int -> 'a) -> 'a BatVect.Make.t
val get : 'a BatVect.Make.t -> n:int -> 'a
val at : 'a BatVect.Make.t -> n:int -> 'a
val set :
'a BatVect.Make.t -> n:int -> elem:'a -> 'a BatVect.Make.t
val modify :
'a BatVect.Make.t -> n:int -> f:('a -> 'a) -> 'a BatVect.Make.t
val destructive_set :
'a BatVect.Make.t -> n:int -> elem:'a -> unit
val sub :
'a BatVect.Make.t -> m:int -> n:int -> 'a BatVect.Make.t
val insert :
n:int ->
sub:'a BatVect.Make.t -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val remove :
m:int -> n:int -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val iter : f:('a -> unit) -> 'a BatVect.Make.t -> unit
val iteri : f:(int -> 'a -> unit) -> 'a BatVect.Make.t -> unit
val rangeiter :
f:('a -> unit) -> m:int -> n:int -> 'a BatVect.Make.t -> unit
val fold_left :
f:('b -> 'a -> 'b) -> init:'b -> 'a BatVect.Make.t -> 'b
val fold :
f:('b -> 'a -> 'b) -> init:'b -> 'a BatVect.Make.t -> 'b
val reduce : f:('a -> 'a -> 'a) -> 'a BatVect.Make.t -> 'a
val fold_right :
f:('a -> 'b -> 'b) -> 'a BatVect.Make.t -> init:'b -> 'b
val foldi :
f:(int -> 'b -> 'a -> 'b) -> init:'b -> 'a BatVect.Make.t -> 'b
val map : f:('a -> 'b) -> 'a BatVect.Make.t -> 'b BatVect.Make.t
val mapi :
f:(int -> 'a -> 'b) -> 'a BatVect.Make.t -> 'b BatVect.Make.t
val for_all : f:('a -> bool) -> 'a BatVect.Make.t -> bool
val exists : f:('a -> bool) -> 'a BatVect.Make.t -> bool
val find : f:('a -> bool) -> 'a BatVect.Make.t -> 'a
val mem : elem:'a -> 'a BatVect.Make.t -> bool
val memq : elem:'a -> 'a BatVect.Make.t -> bool
val findi : f:('a -> bool) -> 'a BatVect.Make.t -> int
val filter :
f:('a -> bool) -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val filter_map :
f:('a -> 'b option) -> 'a BatVect.Make.t -> 'b BatVect.Make.t
val find_all :
f:('a -> bool) -> 'a BatVect.Make.t -> 'a BatVect.Make.t
val partition :
f:('a -> bool) ->
'a BatVect.Make.t -> 'a BatVect.Make.t * 'a BatVect.Make.t
end
val print :
?first:string ->
?last:string ->
?sep:string ->
('a BatInnerIO.output -> 'b -> unit) ->
'a BatInnerIO.output -> 'b BatVect.Make.t -> unit
val invariants : 'a BatVect.Make.t -> unit
end
end