Module Monoid.Make

Make(Base) derives a monoid from its minimal definition

Parameters

module M : Base

Signature

include Base with type t := M.t
val zero : M.t

zero an element that is neutral to plus

val plus : M.t -> M.t -> M.t

plus x y an associative operation.

val concat : M.t list -> M.t

concat xs reduces xs to using plus

val (@@) : M.t -> M.t -> M.t

x @@ y is plus x y