Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Copilot.Language.Operators.Mux
Description
Pick values from one of two streams, depending whether a condition is true or false.
Documentation
mux :: Typed a => Stream Bool -> Stream a -> Stream a -> Stream a Source #
Convenient synonym for ifThenElse
.
ifThenElse :: Typed a => Stream Bool -> Stream a -> Stream a -> Stream a Source #
If-then-else applied point-wise to three streams (a condition stream, a then-branch stream, and an else-branch stream).
Produce a stream that, at any point in time, if the value of the first stream at that point is true, contains the value in the second stream at that time, otherwise it contains the value in the third stream.