transformers-0.4.1.0: Concrete functor and monad transformers

Portability | portable
Stability | experimental
Maintainer | ross@soi.city.ac.uk
Safe Haskell | Safe-Inferred

Data.Functor.Identity

Description

The identity functor and monad.

This trivial type constructor serves two purposes:

- It can be used with functions parameterized by functor or monad classes.
- It can be used as a base monad to which a series of monad transformers may be applied to construct a composite monad. Most monad transformer modules include the special case of applying the transformer to `Identity`. For example, `State s` is an abbreviation for `StateT s `Identity``.

Synopsis

- newtype Identity a = Identity {
  - runIdentity :: a
  }

# Documentation

newtype Identity a

Identity functor and monad. (a non-strict monad)

Constructors

Identity |

Fields

runIdentity :: a

Instances

Monad Identity |
Functor Identity |
MonadFix Identity |
Applicative Identity |
Foldable Identity |
Traversable Identity |
Show1 Identity |
Read1 Identity |
Ord1 Identity |
Eq1 Identity |
Eq a => Eq (Identity a) |
Ord a => Ord (Identity a) |
Read a => Read (Identity a) |
Show a => Show (Identity a) |