MPL11
|
The Monoid
typeclass is used for datatypes with an associative binary operation that has an identity.
More...
Classes | |
struct | boost::mpl11::plus< x1, x2, xn > |
Associative operation on a Monoid . More... | |
struct | boost::mpl11::zero< Datatype > |
Additive identity for the given Datatype . More... | |
The Monoid
typeclass is used for datatypes with an associative binary operation that has an identity.
Instances of Monoid
must satisfy the following laws:
The method names refer to the monoid of numbers under addition, but there are many other instances such as sequences under concatenation. Some datatypes can be viewed as a monoid in more than one way, e.g. both addition and multiplication on numbers.
plus
and zero
All the methods.