Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Provides handle-closing.
Synopsis
- class Monad m => ChFinalizer m where
- newtype HandleCloserT m a = HandleCloser {
- runHandleCloserT :: [Handle] -> m (a, [Handle])
- withLazyIO :: (MonadIO m, Functor m) => HandleCloserT m a -> m a
Documentation
class Monad m => ChFinalizer m where Source #
Class for all handle-finalizing monads. Required for file redirections.
mqfh :: Handle -> m () Source #
Enqueue handle
mqfhs :: [Handle] -> m () Source #
Enqueue list of handles
Finalize all queued handles
Instances
newtype HandleCloserT m a Source #
Handle-closing transformer
HandleCloser | |
|
Instances
withLazyIO :: (MonadIO m, Functor m) => HandleCloserT m a -> m a Source #
Run function with handle closer