IdrisDoc: Prelude.Monad

Prelude.Monad

Monads and Functors

return : Monad m => a -> m a

For compatibility with Haskell. Note that monads are not free to
define return and pure differently!

foldlM : Foldable t => Monad m => (funcM : a -> b -> m a) -> (init : a) -> (input : t b) -> m a

Similar to foldl, but uses a function wrapping its result in a Monad.
Consequently, the final value is wrapped in the same Monad.

default#join : Monad m => m (m a) -> m a
default#>>= : Monad m => m a -> (a -> m b) -> m b
interface Monad 
(>>=) : Monad m => m a -> (a -> m b) -> m b

Also called bind.

Fixity
Left associative, precedence 1
join : Monad m => m (m a) -> m a

Also called flatten or mu