chatty-0.2.0.1: Some monad transformers and typeclasses to simplify I/O on a transformer stack.

Safe HaskellSafe-Inferred

Text.Chatty.Finalizer

Synopsis

Documentation

class Monad m => MonadFinalizer m whereSource

Class for all handle-finalizing monads. Required for file redirections.

Methods

mqfh :: Handle -> m ()Source

Enqueue handle

mqfhs :: [Handle] -> m ()Source

Enqueue list of handles

mfin :: m ()Source

Finalize all queued handles

withLazyIO :: (MonadIO m, Functor m) => HandleCloserT m a -> m aSource

Run function with handle closer