async-fuse
Helpers for fusing asynchronous computations.
This is especially useful in combination with optional branches using tokio::select, where the future being polled isn't necessarily set.
A similar structure is provided by futures-rs called Fuse. This however lacks some of the flexibility needed to interact with tokio's streaming types like Interval since these no longer implement Stream.
Examples
This is available as the
tickerexample:
use Duration;
use time;
let mut interval = poll_fn;
let sleep = once;
pin!;
for _ in 0..20usize
License: MIT/Apache-2.0