úÎBò?%      !"#$ non-portable experimentalEdward Kmett <ekmett@gmail.com> TrustworthyGeneralized version of % EThrow an exception. Note that this throws when this action is run in  the monad m4, not when it is applied. It is a generalization of  Control.Exception's &. FProvide a handler for exceptions thrown during execution of the first H action. Note that type of the type of the argument to the handler will , constrain which exceptions are caught. See Control.Exception's  '. DRuns an action with asynchronous exceptions disabled. The action is G provided a method for restoring the async. environment to what it was  at the   call. See Control.Exception's (. Like  7, but the masked computation is not interruptible (see  Control.Exception's ) . WARNING: K Only use if you need to mask exceptions around an interruptible operation I AND you can guarantee the interruptible operation will only block for a 7 short period of time. Otherwise you render the program/thread unresponsive  and/or unkillable. Like  , but does not pass a restore action to the argument. Like  , but does not pass a restore action to the  argument. KCatches all exceptions, and somewhat defeats the purpose of the extensible " exception system. Use sparingly.  Catch all * (eqv.  IOException!) exceptions. Still somewhat too  general, but better than using . See  for an easy way  of catching specific *s based on the predicates in System.IO.Error. ICatch exceptions only if they pass some predicate. Often useful with the  predicates for testing * values in System.IO.Error. CA more generalized way of determining which exceptions to catch at  run time. Flipped  . See Control.Exception's +. Flipped  Flipped  Flipped  Flipped . See Control.Exception's ,.  Similar to  , but returns an - result. See Control.Exception's  .  A variant of - that takes an exception predicate to select " which exceptions are caught. See Control.Exception's . +Catches different sorts of exceptions. See Control.Exception's / ERun an action only if an exception is thrown in the main action. The + exception is not caught, simply rethrown. HGeneralized abstracted pattern of safe resource acquisition and release - in the face of exceptions. The first action "acquires" some value, which  is "released"3 by the second action at the end. The third action "uses" / the value and its result is the result of the . LIf an exception occurs during the use, the release still happens before the  exception is rethrown.  Version of 2 without any value being passed to the second and  third actions. BPerform an action with a finalizer action that is run, even if an  exception occurs. Like 5, but only performs the final action if there was an 1 exception raised by the in-between computation. $ 0123456789   0123456789 non-portable experimentalEdward Kmett <ekmett@gmail.com> Trustworthy Add  handling abilities to a :.  This should never be used in combination with ; . Think of   K as an alternative base monad for use with mocking code that solely throws  exceptions via .  Note: that ;0 monad has these abilities already, so stacking   on top = of it does not add any value and can possibly be confusing: I(error "Hello!" :: IO ()) `catch` (\(e :: ErrorCall) -> liftIO $ print e)Hello!\runCatchT $ (error "Hello!" :: CatchT IO ()) `catch` (\(e :: ErrorCall) -> liftIO $ print e)*** Exception: Hello!irunCatchT $ (throwM (ErrorCall "Hello!") :: CatchT IO ()) `catch` (\(e :: ErrorCall) -> liftIO $ print e)Hello!$8Map the unwrapped computation using the given function.   runErrorT ( mapErrorT f m) = f ( runErrorT m)  !"#$<=>?@ABCDEFGHIJ%  !"#$ !"#$ !"#$<=>?@ABCDEFGHIJK       !"#$$%&' ()*((+,**-.*/0123456789:;<=>?@ABCDEFGHIJKLMexceptions-0.3.2Control.Monad.CatchControl.Monad.Catch.PureControl.Exceptiontrybase GHC.Exception SomeException fromException toException ExceptionHandler MonadCatchthrowMcatchmaskuninterruptibleMaskmask_uninterruptibleMask_catchAll catchIOErrorcatchIf catchJusthandle handleIOError handleAllhandleIf handleJusttryJustcatches onExceptionbracketbracket_finallybracketOnErrorCatchCatchT runCatchTrunCatch mapCatchTGHC.IOthrowIOControl.Exception.BaseGHC.IO.ExceptionIOError Data.EitherEither$fFunctorHandler$fMonadCatchRWST$fMonadCatchRWST0$fMonadCatchWriterT$fMonadCatchWriterT0$fMonadCatchReaderT$fMonadCatchStateT$fMonadCatchStateT0$fMonadCatchIdentityT$fMonadCatchIOGHC.BaseMonadghc-prim GHC.TypesIO$fMonadRWSrwsCatchT$fMonadWriterwCatchT$fMonadReadereCatchT$fMonadStatesCatchT$fMonadCatchCatchT$fMonadIOCatchT$fMonadTransCatchT$fMonadPlusCatchT$fAlternativeCatchT$fTraversableCatchT$fFoldableCatchT$fMonadFixCatchT $fMonadCatchT$fApplicativeCatchT$fFunctorCatchT