Macro frappe::sample_with
[−]
[src]
macro_rules! sample_with { (@impl $f:expr ; ; $($var:ident)+) => { ... }; (@impl $f:expr ; $sig:expr, $($tail:expr,)* ; $($var:ident)*) => { ... }; (@named ; ; $e:expr) => { ... }; (@named $sig:expr, $($stail:expr,)* ; $var:ident $($vtail:ident)* ; $e:expr) => { ... }; ($($sig:expr),+ ; $f:expr) => { ... }; ($($sig:expr),+ => | $($var:ident),+ | $e:expr) => { ... }; }
Helper for using Signal::sample_with
with multiple signals.
Called as: sample_with!(s1, s2, ...; f)
where:
s1: Signal<S1>, s2: Signal<S2>, ...
are N input signalsf(MaybeOwned<S1>, MaybeOwned<S2>, ...) -> R
is a function that takes N arguments
or as: sample_with!(s1, s2, ... => |v1, v2, ...| expr)
where:
v1: MaybeOwned<S1>, v2: MaybeOwned<S2>, ...
are N variable namesexpr
is an expresion using those variables