monadio-unwrappable-0.3: Reversibly allow monad transformer stacks to run in IO

Safe HaskellSafe-Infered

Control.Monad.IO.MonadIOException

Synopsis

Documentation

bracketIOSource

Arguments

:: MonadIOUnwrappable m 
=> IO a

The operation to perform initially.

-> (a -> IO b)

The cleanup that should always be performed

-> (a -> m c)

The monad transformer stack to execute.

-> m c 

Guarantees that an IO operation will be performed before an after executing | a MonadIOUnwrappable monad. The operation will be performed even if the | MonadIO contains error monads that fails, or if an exception is raised.