packages feed

enclosed-exceptions 1.0.0.1 → 1.0.0.2

raw patch · 2 files changed

+7/−2 lines, 2 filesdep +transformers-base

Dependencies added: transformers-base

Files

enclosed-exceptions.cabal view
@@ -1,8 +1,10 @@ name:                enclosed-exceptions-version:             1.0.0.1+version:             1.0.0.2 synopsis:            Catching all exceptions from within an enclosed computation description:         Catching all exceptions raised within an enclosed computation,                      while remaining responsive to (external) asynchronous exceptions.+                     For more information on the technique, please see:+                     <https://www.fpcomplete.com/user/snoyberg/general-haskell/exceptions/catching-all-exceptions> homepage:            https://github.com/jcristovao/enclosed-exceptions license:             MIT license-file:        LICENSE@@ -21,6 +23,7 @@                      , monad-control                      , async                         >= 2.0                      , deepseq+                     , transformers-base   ghc-options:         -Wall -fno-warn-orphans  test-suite test@@ -35,6 +38,7 @@                    , hspec                         >= 1.3                    , QuickCheck                    , transformers+                   , transformers-base     ghc-options:     -Wall  source-repository head
src/Control/Exception/Enclosed.hs view
@@ -50,6 +50,7 @@ import Prelude import Control.Exception.Lifted import Control.Monad (liftM)+import Control.Monad.Base (liftBase) import Control.Monad.Trans.Control (MonadBaseControl, liftBaseWith, restoreM) import Control.Concurrent.Async (withAsync, waitCatch) import Control.DeepSeq (NFData, ($!!))@@ -112,7 +113,7 @@            -> m (Either SomeException a) tryAnyDeep m = tryAny $ do     x <- m-    return $!! x+    liftBase $ evaluate $!! x  -- | A version of 'catch' which is specialized for IO exceptions. This -- simplifies usage as no explicit type signatures are necessary.