pipes-extra-0.2.0: Various basic utilities for Pipes.

Control.Pipe.Coroutine

data Coroutine a b m r Source

resume :: Coroutine a b m r -> Pipe a b m rSource

suspend :: Monad m => Pipe a b m r -> Pipe a x m (Either r (b, Coroutine a b m r))Source

coroutine :: Monad m => Pipe a b m r -> Coroutine a b m rSource

step :: Monad m => Coroutine a b m r -> Pipe a x m (Either r (b, Coroutine a b m r))Source

terminate :: Monad m => Coroutine a b m r -> Pipe a b m ()Source