effect-handlers-0.1.0.4: A library for writing extensible algebraic effects and handlers. Similar to extensible-effects but with deep handlers.

Safe HaskellNone
LanguageHaskell2010

Control.Effects.IO

Synopsis

Documentation

data LiftIO a Source

The functor representing the effect. You shouldn't need to create this manually, just use liftIO.

Constructors

forall r . LiftIO (IO r) (r -> a) 

Instances

liftIO :: Member LiftIO r => IO a -> Eff r a Source

Lift an existing IO action into the effect monad.

ioHandler :: Handler LiftIO [] a (IO a) Source

Handle by converting back to IO. Note that it is required that the effect stack is otherwise empty - this handler would not typecheck otherwise.