A map that folds in new values.
An example would be a multi-map in which a key is initialized with the empty list as its value, and adding a new key/value pair appends the value to the key's list.
module Make : functor (Fold : Foldable) -> S with type in_value = Fold.data and type out_value = Fold.tBuilds a fold_map
Same as above but builds the sexp_of and of_sexp functions. Requires the
passed in types to be sexpable.
module type S_sexpable : sig ... endmodule type Foldable_sexpable : sig ... endmodule Make_sexpable : functor (Fold : Foldable_sexpable) -> S_sexpable with type in_value = Fold.data and type out_value = Fold.tPolymorphic fold take a
module type Foldable2 : sig ... endmodule type S2 : sig ... endmodule type Foldable2_sexpable : sig ... endmodule type S2_sexpable : sig ... endmodule Make2_sexpable : functor (Fold : Foldable2_sexpable) -> S2_sexpable with type 'a out_value = 'a Fold.tmodule Cons : S2_sexpable with type 'a out_value = 'a listmodule Add : S_sexpable with type in_value = int and type out_value = intA fold for adding. e.g. symbol positions
module Multiply : S_sexpable with type in_value = int and type out_value = int