[−][src]Function safina::select_abcde
pub async fn select_abcde<A, B, C, D, E, FutA, FutB, FutC, FutD, FutE>(
a: FutA,
b: FutB,
c: FutC,
d: FutD,
e: FutE
) -> OptionABCDE<A, B, C, D, E> where
FutA: Future<Output = A> + Send + 'static,
FutB: Future<Output = B> + Send + 'static,
FutC: Future<Output = C> + Send + 'static,
FutD: Future<Output = D> + Send + 'static,
FutE: Future<Output = E> + Send + 'static,
Awaits the futures and returns the value from the one that completes first.
First moves them to the heap, to make them
Unpin
.
Use
SelectFuture::new
to avoid allocating on the heap.