package gen

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type 'a t
val empty : 'a t
val singleton : 'a -> 'a t
val repeat : 'a -> 'a t
val iterate : 'a -> ('a -> 'a) -> 'a t
val unfold : ('b -> ('a * 'b) option) -> 'b -> 'a t
val init : ?limit:int -> (int -> 'a) -> 'a t
val is_empty : 'a t -> bool
val fold : ('b -> 'a -> 'b) -> 'b -> 'a t -> 'b
val reduce : ('a -> 'a -> 'a) -> 'a t -> 'a
val scan : ('b -> 'a -> 'b) -> 'b -> 'a t -> 'b t
val iter : ('a -> unit) -> 'a t -> unit
val iteri : (int -> 'a -> unit) -> 'a t -> unit
val length : 'a t -> int
val map : ('a -> 'b) -> 'a t -> 'b t
val append : 'a t -> 'a t -> 'a t
val flatten : 'a gen t -> 'a t
val flat_map : ('a -> 'b gen) -> 'a t -> 'b t
val mem : ?eq:('a -> 'a -> bool) -> 'a -> 'a t -> bool
val take : int -> 'a t -> 'a t
val drop : int -> 'a t -> 'a t
val nth : int -> 'a t -> 'a
val take_nth : int -> 'a t -> 'a t
val filter : ('a -> bool) -> 'a t -> 'a t
val take_while : ('a -> bool) -> 'a t -> 'a t
val drop_while : ('a -> bool) -> 'a t -> 'a t
val filter_map : ('a -> 'b option) -> 'a t -> 'b t
val zip_index : 'a t -> (int * 'a) t
val unzip : ('a * 'b) t -> 'a t * 'b t
val partition : ('a -> bool) -> 'a t -> 'a t * 'a t
val for_all : ('a -> bool) -> 'a t -> bool
val exists : ('a -> bool) -> 'a t -> bool
val min : ?lt:('a -> 'a -> bool) -> 'a t -> 'a
val max : ?lt:('a -> 'a -> bool) -> 'a t -> 'a
val eq : ?eq:('a -> 'a -> bool) -> 'a t -> 'a t -> bool
val lexico : ?cmp:('a -> 'a -> int) -> 'a t -> 'a t -> int
val compare : ?cmp:('a -> 'a -> int) -> 'a t -> 'a t -> int
val find : ('a -> bool) -> 'a t -> 'a option
val sum : int t -> int
val map2 : ('a -> 'b -> 'c) -> 'a t -> 'b t -> 'c t
val iter2 : ('a -> 'b -> unit) -> 'a t -> 'b t -> unit
val fold2 : ('acc -> 'a -> 'b -> 'acc) -> 'acc -> 'a t -> 'b t -> 'acc
val for_all2 : ('a -> 'b -> bool) -> 'a t -> 'b t -> bool
val exists2 : ('a -> 'b -> bool) -> 'a t -> 'b t -> bool
val zip_with : ('a -> 'b -> 'c) -> 'a t -> 'b t -> 'c t
val zip : 'a t -> 'b t -> ('a * 'b) t
val merge : 'a gen t -> 'a t
val intersection : ?cmp:('a -> 'a -> int) -> 'a t -> 'a t -> 'a t
val sorted_merge : ?cmp:('a -> 'a -> int) -> 'a t -> 'a t -> 'a t
val sorted_merge_n : ?cmp:('a -> 'a -> int) -> 'a t list -> 'a t
val tee : ?n:int -> 'a t -> 'a gen list
val round_robin : ?n:int -> 'a t -> 'a gen list
val interleave : 'a t -> 'a t -> 'a t
val intersperse : 'a -> 'a t -> 'a t
val product : 'a t -> 'b t -> ('a * 'b) t
val group : ?eq:('a -> 'a -> bool) -> 'a t -> 'a list t
val uniq : ?eq:('a -> 'a -> bool) -> 'a t -> 'a t
val sort : ?cmp:('a -> 'a -> int) -> 'a t -> 'a t
val sort_uniq : ?cmp:('a -> 'a -> int) -> 'a t -> 'a t
val chunks : int -> 'a t -> 'a array t
val of_list : 'a list -> 'a t
val to_list : 'a t -> 'a list
val to_rev_list : 'a t -> 'a list
val to_array : 'a t -> 'a array
val of_array : ?start:int -> ?len:int -> 'a array -> 'a t
val rand_int : int -> int t
val int_range : int -> int -> int t
module Infix : sig ... end
val (--) : int -> int -> int t
val (>>=) : 'a t -> ('a -> 'b gen) -> 'b t
val pp : ?start:string -> ?stop:string -> ?sep:string -> ?horizontal:bool -> (Format.formatter -> 'a -> unit) -> Format.formatter -> 'a t -> unit
OCaml

Innovation. Community. Security.