| Copyright | (c) Ross Paterson 2012 |
|---|---|
| License | BSD-style (see the file LICENSE) |
| Maintainer | [email protected] |
| Stability | experimental |
| Portability | portable |
| Safe Haskell | Safe |
| Language | Haskell2010 |
Signatures for monad operations that require specialized lifting. Each signature has a uniformity property that the lifting should satisfy.
type CallCC (m :: Type -> Type) a b = ((a -> m b) -> m a) -> m a Source
Signature of the callCC operation, introduced in Control.Monad.Trans.Cont. Any lifting function liftCallCC should satisfy
lift (f k) = f' (lift . k) => lift (cf f) = liftCallCC cf f'
This implies that on entry to the continuation any outer monad transformer effect inside callCC will have been rolled back.
type Catch e (m :: k -> Type) (a :: k) = m a -> (e -> m a) -> m a Source
Signature of the catchE operation, introduced in Control.Monad.Trans.Except. Any lifting function liftCatch should satisfy
lift (cf m h) = liftCatch cf (lift m) (lift . h)
This implies that on entry to the handler function any outer monad transformer effect inside catchE will have been rolled back.
type Listen w (m :: Type -> Type) a = m a -> m (a, w) Source
Signature of the listen operation, introduced in Control.Monad.Trans.Writer. Any lifting function liftListen should satisfy
lift . liftListen = liftListen . lift
type Pass w (m :: Type -> Type) a = m (a, w -> w) -> m a Source
Signature of the pass operation, introduced in Control.Monad.Trans.Writer. Any lifting function liftPass should satisfy
lift . liftPass = liftPass . lift
© The University of Glasgow and others
Licensed under a BSD-style license (see top of the page).
https://downloads.haskell.org/~ghc/9.12.1/docs/libraries/transformers-0.6.1.2-72bd/Control-Monad-Signatures.html