pub trait Race {
type Output;
type Future: Future<Output = Self::Output>;
// Required method
fn race(self) -> Self::Future;
}
Expand description
Wait for the first future to complete.
Awaits multiple future at once, returning as soon as one completes. The other futures are cancelled.