netwire-2.0.1: Generic automaton arrow transformer and useful tools

MaintainerErtugrul Soeylemez <>




Wires for signal accumulation.


General accumulator

accum :: a -> Wire e >~ (a -> a) aSource

General accumulator. Outputs the argument value at the first instant, then applies the input function repeatedly for subsequent instants. This acts like the iterate function for lists.

  • Depends: current instant.

Special accumulators

countFrom :: Enum b => b -> Wire e >~ a bSource

Count upwards from the given starting value.

countStep :: Num a => a -> Wire e >~ a aSource

Count from the given starting value, repeatedly adding the input signal to it.

  • Depends: current instant.

Specific instances

atFirst :: (b -> b) -> Wire e >~ b bSource

Apply the given function at the first instant. Then act as the identity wire forever.

  • Depends: Current instant.