Expand description
Monads with a choice operator and identity element, combining Monad and Alternative.
A MonadPlus is a type that supports both monadic sequencing
(Monad) and choice with an identity element
(Alternative). It has no members of its own; it specifies that
the type constructor has both Monad and Alternative instances.
This module is a port of PureScript’s
Control.MonadPlus.
§Hierarchy
Functor
|
+-- Pointed + Semiapplicative --> Applicative
|
+-- Applicative + Semimonad ----> Monad
|
+-- Alt + (identity element) ---> Plus
|
+-- Applicative + Plus ---------> Alternative
|
+-- Monad + Alternative --------> MonadPlusTraits§
- Monad
Plus - A type class for monads that also support choice, combining
MonadandAlternative.