monad-abort-fd-0.2: A better error monad transformer

Control.Monad.Abort

Documentation

class Monad μ => MonadAbort e μ | μ -> e whereSource

Methods

abort :: e -> μ αSource

Instances

MonadAbort SomeException IO 
MonadAbort e μ => MonadAbort e (ListT μ) 
MonadAbort e μ => MonadAbort e (MaybeT μ) 
MonadAbort e μ => MonadAbort e (IdentityT μ) 
(MonadAbort e μ, Monoid w) => MonadAbort e (WriterT w μ) 
(MonadAbort e μ, Monoid w) => MonadAbort e (WriterT w μ) 
MonadAbort e μ => MonadAbort e (StateT s μ) 
MonadAbort e μ => MonadAbort e (StateT s μ) 
MonadAbort e μ => MonadAbort e (ReaderT r μ) 
MonadAbort e μ => MonadAbort e (ContT r μ) 
Monad μ => MonadAbort e (AbortT e μ) 
MonadAbort e μ => MonadAbort e (FinishT f μ) 
(MonadAbort e μ, Monoid w) => MonadAbort e (RWST r w s μ) 
(MonadAbort e μ, Monoid w) => MonadAbort e (RWST r w s μ) 

class MonadAbort e μ => MonadRecover e μ | μ -> e whereSource

Methods

recover :: μ α -> (e -> μ α) -> μ αSource

Instances

MonadRecover SomeException IO 
MonadRecover e μ => MonadRecover e (ListT μ) 
MonadRecover e μ => MonadRecover e (MaybeT μ) 
MonadRecover e μ => MonadRecover e (IdentityT μ) 
(MonadRecover e μ, Monoid w) => MonadRecover e (WriterT w μ) 
(MonadRecover e μ, Monoid w) => MonadRecover e (WriterT w μ) 
MonadRecover e μ => MonadRecover e (StateT s μ) 
MonadRecover e μ => MonadRecover e (StateT s μ) 
MonadRecover e μ => MonadRecover e (ReaderT r μ) 
Monad μ => MonadRecover e (AbortT e μ) 
MonadRecover e μ => MonadRecover e (FinishT f μ) 
(MonadRecover e μ, Monoid w) => MonadRecover e (RWST r w s μ) 
(MonadRecover e μ, Monoid w) => MonadRecover e (RWST r w s μ) 

onError :: MonadRecover e μ => μ α -> (e -> μ β) -> μ αSource

onError_ :: MonadRecover e μ => μ α -> μ β -> μ αSource

type Abort e α = AbortT e Identity α

runAbort :: Abort e α -> Either e α

newtype AbortT e μ α

Constructors

AbortT 

Fields

runAbortT :: μ (Either e α)
 

Instances

MonadRWS r w s μ => MonadRWS r w s (AbortT e μ) 
Monad μ => Failure e (AbortT e μ) 
Monad μ => MonadError e (AbortT e μ) 
MonadReader r μ => MonadReader r (AbortT e μ) 
MonadState s μ => MonadState s (AbortT e μ) 
MonadWriter w μ => MonadWriter w (AbortT e μ) 
Monad μ => MonadRecover e (AbortT e μ) 
Monad μ => MonadAbort e (AbortT e μ) 
MonadMask m μ => MonadMask m (AbortT e μ) 
MonadFinish f μ => MonadFinish f (AbortT e μ) 
MonadTrans (AbortT e) 
MonadTransControl (AbortT e) 
BindTrans (AbortT e) 
Monad μ => Monad (AbortT e μ) 
Functor μ => Functor (AbortT e μ) 
MonadFix μ => MonadFix (AbortT e μ) 
(Monad μ, Default e) => MonadPlus (AbortT e μ) 
(Functor μ, Monad μ) => Applicative (AbortT e μ) 
(Functor μ, Monad μ, Default e) => Alternative (AbortT e μ) 
MonadIO μ => MonadIO (AbortT e μ) 
MonadControlIO μ => MonadControlIO (AbortT e μ) 
MonadCont μ => MonadCont (AbortT e μ) 
Monad μ => Pointed (AbortT e μ) 
(Functor μ, Monad μ, Default e) => Plus (AbortT e μ) 
(Functor μ, Monad μ) => Alt (AbortT e μ) 
(Functor μ, Monad μ) => Apply (AbortT e μ) 
(Functor μ, Monad μ) => Bind (AbortT e μ) 
MonadFinally μ => MonadFinally (AbortT e μ) 
MonadBaseControl μ η => MonadBaseControl (AbortT e μ) η 
MonadBase μ η => MonadBase (AbortT e μ) η