Safe Haskell | Safe-Inferred |
---|

# Documentation

class Monad m => MonadTimeout w m | m -> w whereSource

Monad for computations that can save partial results
of type `w`

during their evaluation.

Save an intermediate result of the computation.

tellWith :: (Maybe w -> w) -> m ()Source

Combine an intermediate result of the computation with the current saved result (if any) and save it.

Explicitly allow interrupting the computation at this point. Experimental.

Monad (Timeout w) => MonadTimeout w (Timeout w) |

An `IO`

-based implementation of `MonadTimeout`

.

returning :: MonadTimeout w m => m w -> m ()Source

Convert a monadic computation returning a value of the result type into
'm ()' so that it can be used with `runTimeout`

. Calling 'returning k'
is equivalent to 'k >>= tell'.