control-monad-failure-0.2: A class for monads which can fail with an error.Source codeContentsIndex
Control.Monad.Failure.Class
Description
Defines the class MonadFailure for monads which can fail.
Documentation
class Monad m => MonadFailure e m whereSource
Methods
failure :: e -> m aSource
show/hide Instances
class MonadFailure e m => WrapFailure e m whereSource
Methods
wrapFailure :: (forall eIn. Exception eIn => eIn -> e) -> m a -> m aSource
Wrap the failure value, if any, with the given function. This is useful in particular when you want all the exceptions returned from a certain library to be of a certain type, even if they were generated by a different library.
show/hide Instances
Produced by Haddock version 2.6.0