io-choice-0.0.2: Choice for IO and lifted IO

Safe HaskellSafe-Infered

Control.Exception.IOChoice.Lifted

Description

This package provides the choice operator (||>) for lifted IO monad.

Synopsis

Documentation

(||>) :: MonadBaseControl IO m => m a -> m a -> m aSource

If IOException occurs or goNext is used in the left monad, then the right monad is performed. Note that fail throws IOException.

goNext :: (MonadIO m, MonadBase IO m) => m aSource

Go to the next IO monad by throwing IOException.

runAnyOne :: (MonadIO m, MonadBaseControl IO m) => [m a] -> m aSource

Run any one lifted IO monad.