Copyright | (c) 2007 Magnus Therning |
---|---|
License | BSD-style (see the file LICENSE) |
Maintainer | R.Paterson@city.ac.uk |
Stability | experimental |
Portability | portable |
Safe Haskell | Safe |
Language | Haskell98 |
Control.Monad.Trans.Identity
Description
The identity monad transformer.
This is useful for functions parameterized by a monad transformer.
Synopsis
-
newtype
IdentityT
f a =
IdentityT
{
- runIdentityT :: f a
- mapIdentityT :: (m a -> n b) -> IdentityT m a -> IdentityT n b
- liftCatch :: Catch e m a -> Catch e ( IdentityT m) a
- liftCallCC :: CallCC m a b -> CallCC ( IdentityT m) a b
The identity monad transformer
newtype IdentityT f a Source #
The trivial monad transformer, which maps a monad to an equivalent monad.
Constructors
IdentityT | |
Fields
|
Instances
mapIdentityT :: (m a -> n b) -> IdentityT m a -> IdentityT n b Source #
Lift a unary operation to the new monad.