HORIZON HASKELLDocslts/ghc-9.14.xd82dee82026-10-12Search names, modules, packages, or :: a typeCtrl K

GHC 9.14.1 · lts/ghc-9.14.x · d82dee8 · 2026-10-12

Modulemachines-0.7.4Haskell2010

Data.Machine.Wye

  • 3 types
  • 6 values
  • Packagemachines-0.7.4
  • Exports9
  • LanguageHaskell2010
  • LicenceBSD-3-Clause
  • SourceWye.hs

Wyes

9 declarations
typetype Wye a b c = Machine (Y a b) c
#

A Machine that can read from two input stream in a non-deterministic manner.

typetype WyeT (m :: Type -> Type) a b c = MachineT m (Y a b) c
#

A Machine that can read from two input stream in a non-deterministic manner with monadic side-effects.

datadata Y a b c where
#

The input descriptor for a Wye or WyeT

Constructors

valuewye
  1. :: Monad m
  2. => ProcessT m a a'
  3. -> ProcessT m b b'
  4. -> WyeT m a' b' c
  5. -> WyeT m a b c
#

Compose a pair of pipes onto the front of a Wye.

Precompose a Process onto each input of a Wye (or WyeT).

This is left biased in that it tries to draw values from the X input whenever they are available, and only draws from the Y input when X would block.