Up

Module type Creators2

Signature

type ('a, 'b) t
type ('a, 'b) tree
val empty : (_, _) t
val singleton : 'a -> 'b -> ('a, 'b) t
val of_alist : ('a * 'b) list -> [
| `Ok of ('a, 'b) t
| `Duplicate_key of 'a
]
val of_alist_or_error : ('a * 'b) list -> ('a, 'b) t Or_error.t
val of_alist_exn : ('a * 'b) list -> ('a, 'b) t
val of_alist_multi : ('a * 'b) list -> ('a, 'b list) t
val of_alist_fold : ('a * 'b) list -> init:'c -> f:('c -> 'b -> 'c) -> ('a, 'c) t
val of_alist_reduce : ('a * 'b) list -> f:('b -> 'b -> 'b) -> ('a, 'b) t
val of_sorted_array : ('a * 'b) array -> ('a, 'b) t Or_error.t
val of_sorted_array_unchecked : ('a * 'b) array -> ('a, 'b) t
val of_tree : ('a, 'b) tree -> ('a, 'b) t