MHask-0.3.0.0: The category of monads

Safe HaskellSafe-Inferred

MHask.Indexed.Monad

Description

Compare to indexed.Control.Monad.Indexed (IxMonad)

Synopsis

Documentation

class IxPointed t => IxMonad t whereSource

Indexed version of MHask.Monad. Dual of MHask.Indexed.Comonad

Methods

ijoin :: Monad m => t i j (t j k m) ~> t i k mSource

ibind :: (Monad m, Monad n) => (m ~> t j k n) -> t i j m ~> t i k nSource

imapMonad :: (Monad m, Monad n, Monad (t j j n), IxMonad t) => (m ~> n) -> t i j m ~> t i j nSource

If you define your IxMonad in terms of ibind and ireturn, then you get a free implementation of imap which can be used for IxFunctor.