Functors and signatures for dealing with modules for tuples.
These functors allow users to write:
module Foo = struct
include Tuple.Make (String) (Int)
include Tuple.Comparable (String) (Int)
include Tuple.Hashable (String) (Int)
include Tuple.Binable (String) (Int)
endmodule type Comparable_sexpable : sig ... endmodule Comparable : functor (S1 : Comparable_sexpable) -> functor (S2 : Comparable_sexpable) -> Comparable_sexpable with type t := Make(S1)(S2).tmodule type Hashable_sexpable : sig ... endmodule Hashable : functor (S1 : Hashable_sexpable) -> functor (S2 : Hashable_sexpable) -> Hashable_sexpable with type t := Make(S1)(S2).tThe difference between Hashable and Hashable_t functors is that the former's
result type doesn't contain type t and the latter does. Therefore, Hashable can't
be used to combine two pairs into 4-tuple. but Hashable_t can. On the other hand
result of Hashable_t cannot be combined with Comparable.
module Hashable_t : functor (S1 : Hashable_sexpable) -> functor (S2 : Hashable_sexpable) -> Hashable_sexpable with type t = Make(S1)(S2).tmodule Sexpable : functor (S1 : Core_kernel.Sexpable.S) -> functor (S2 : Core_kernel.Sexpable.S) -> Core_kernel.Sexpable.S with type t := Make(S1)(S2).tmodule Binable : functor (B1 : Core_kernel.Binable.S) -> functor (B2 : Core_kernel.Binable.S) -> Core_kernel.Binable.S with type t := Make(B1)(B2).tmodule Hasher : functor (H1 : sig ... end) -> functor (H2 : sig ... end) -> Hashable_sexpable with type t := Make(H1)(H2).t