monad-control
Version 0.3.1.3 revision 0 uploaded by BasVanDijk.
Package meta
- Synopsis
- Lift control operations, like exception catching, through monad transformers
- Description
This package defines the type class
MonadBaseControl
, a subset ofMonadBase
into which generic control operations such ascatch
can be lifted fromIO
or any other base monad. Instances are based on monad transformers inMonadTransControl
, which includes all standard monad transformers in thetransformers
library exceptContT
.See the
lifted-base
package which usesmonad-control
to liftIO
operations from thebase
library (likecatch
orbracket
) into any monad that is an instance ofMonadBase
orMonadBaseControl
.Note that this package is a rewrite of Anders Kaseorg's
monad-peel
library. The main difference is that this package provides CPS style operators and exploits theRankNTypes
andTypeFamilies
language extensions to simplify and speedup most definitions.The following
criterion
based benchmark shows thatmonad-control
is on average about 99% faster thanmonad-peel
:git clone https://github.com/basvandijk/bench-monad-peel-control
- Author
- Bas van Dijk, Anders Kaseorg
- Bug reports
- https://github.com/basvandijk/monad-control/issues
- Category
- Control
- Copyright
- (c) 2011 Bas van Dijk, Anders Kaseorg
- Homepage
- https://github.com/basvandijk/monad-control
- Maintainer
- Bas van Dijk <v.dijk.bas@gmail.com>
- Package URL
- n/a
- Stability
- n/a