transformers-supply: Supply applicative, monad, applicative transformer and monad transformer.
The Supply
monad represents a computation that consumes values from a
provided supply.
This package comes with two separate implementations,
Control.Applicative.Supply
and Control.Monad.Trans.Supply
. The former
provides an applicative and applicative transformer, the latter a monad and
monad transformer.
The reason for providing two separate implementations is that the
Applicative
instance of Control.Monad.Trans.Supply.SupplyT
incurs a
Monad
constraint on the wrapped type, meaning it's not possible to
(usefully) wrap a type that only has an Applicative
instance.
The implementation of Control.Applicative.Supply.SupplyT
has an
Applicative
instance for wrapped types that are only Applicative
, but
this implementation cannot be made an instance of Monad
, meaning it is
less powerful than the version from Control.Monad.Trans.Supply
.
In general, use Control.Monad.Trans.Supply
unless you're wrapping a type
that has no Monad
instance, in which case you can fall back to
Control.Applicative.Supply
.
Downloads
- transformers-supply-0.1.0.tar.gz [browse] (Cabal source package)
- Package description (as included in the package)
Maintainer's Corner
For package maintainers and hackage trustees
Candidates
- No Candidates
Versions [RSS] | 0.1.0 |
---|---|
Dependencies | base (>=4 && <5), mtl (>=2.1), transformers (>=0.3) [details] |
Tested with | ghc ==7.6.3 |
License | BSD-3-Clause |
Copyright | Copyright © 2013 Merijn Verstraaten |
Author | Merijn Verstraaten |
Maintainer | Merijn Verstraaten <merijn@inconsistent.nl> |
Category | System |
Bug tracker | https://bitbucket.org/merijnv/transformers-supply/issues |
Source repo | head: hg clone https://bitbucket.org/merijnv/transformers-supply head: hg clone git+ssh://github.com:merijn/transformers-supply.git |
Uploaded | by MerijnVerstraaten at 2013-07-05T10:36:13Z |
Distributions | |
Reverse Dependencies | 1 direct, 0 indirect [details] |
Downloads | 1227 total (4 in the last 30 days) |
Rating | (no votes yet) [estimated by Bayesian average] |
Your Rating | |
Status | Docs uploaded by user Build status unknown [no reports yet] |