loop -package:pipes-aeson

╭──────────────╮
b │     ╭───╮    │ c
>───┼─────┤   ├────┼───>
│   ┌─┤   ├─┐  │
│ d │ ╰───╯ │  │
│   └───<───┘  │
╰──────────────╯
"for" loop with increment at end of body
A looping operation, where the predicate returns Left as a seed for the next loop or Right to abort the loop.
loop (\x -> if x < 10 then Left $ x * 2 else Right $ show x) 1 == "16"
Combinator for the loop attribute. Example:
div ! loop "bar" $ "Hello."
Result:
<div loop="bar">Hello.</div>
Create a Pipe from a ListT transformation
loop (k1 >=> k2) = loop k1 >-> loop k2

loop return = cat
Efficient loop with an accumulator
Create a loop (feedback) from one node to another one. That is, compute the fix point of a process iteration.
Fast loops (for when GHC can't optimize forM_)
loop start end f: Loops from start to end (inclusive), executing f on each iteration. Same as forM_ [start..end] f. Uses succ inside, which does a bounds (overflow) check.
loops the sample (from begin to end) the specified number of times.
I will call the connection from input to output amplitudes of type amp the looping channel. It is essential, that the looping channel decouples output from input amplitude. You can achieve this by inserting one of the forceAmplitude functions somewhere in the looping channel.
A loop with a break command. Run the action repeatedly until the breaking action is called. The action is run in a scope. See also while.
x <- mutable_ x
loop $ \break -> do
iff_ (x %>= 10) break
x @= x + 1
Like cycle, but return an empty list when the source list is empty.
Type tag for "loopy" trails which return to their starting point.
Run the animation in a loop forever
LOOP, Common Lisp LOOP License, SPDX License List 3.23, SPDX License List 3.25