-
The library now offers both sets and maps. The modules
Baby.H.Set
andBaby.W.Set
continue to exist, and are compatible with OCaml'sSet
library. The modulesBaby.H.Map
andBaby.W.Map
appear, and are compatible with OCaml'sMap
library. Furthermore, the functorsBaby.H.Make
andBaby.W.Make
appear. These functors produce a module that contains sets, maps, and two conversion functions between sets and maps, namelydomain
andlift
. -
Incompatible changes:
- The modules
Baby.H.Set.Int
andBaby.W.Set.Int
have been removed. This makes the library simpler and smaller. UseBaby.H.Set.Make(Int)
andBaby.W.Set.Make(Int)
instead. With theflambda
OCaml compiler, there is no difference in performance. - The functor
Baby.Make
has been renamedBaby.Custom
, and its signature has changed. It now requires two arguments whose signatures areBASE_SET
andBASE_MAP
. - The signature
CORE
has been renamed toBASE_SET
. Furthermore, this signature has changed:- the type
key
has been removed; - the types
tree
andview
are now parameterized; join_weight_balanced
has been renamed to `join_siblings;join_neighbors
has been renamed tojoin_quasi_siblings
.
- the type
- The undocumented modules
Baby.Height
andBaby.Weight
have been removed.
- The modules
-
Documentation: in the signature
OrderedType
, clarify the specification of the functioncompare
; this function decides a total preorder≤
. -
Documentation: in the preamble, clarify that, most of the time, we assume that
≤
is a total order; if an operation must be understood in the more general case where≤
is a total preorder, then this is explicitly indicated. -
Documentation: update the documentation of
find
andfind_opt
in accordance with the previous point.
-
Initial implementation and release. The library offers both height-balanced and weight-balanced binary search trees. Only the
Set
API is supported. -
The library includes two specialized implementations of sets of integers,
Baby.W.Set.Int
andBaby.H.Set.Int
. With the vanilla OCaml compiler, they seem about 20% faster thanBaby.W.Set.Make(Int)
andBaby.H.Set.Make(Int)
. With theflambda
OCaml compiler, there is no difference in performance, as this compiler is capable of inlining functor applications.