pub fn ok<T, E>(t: T) -> FutureResult<T, E>
Expand description
Creates a new future that will immediately resolve successfully to the given value.
ยงExamples
use futures_core::future::*;
let future_of_1 = ok::<u32, u32>(1);
pub fn ok<T, E>(t: T) -> FutureResult<T, E>
Creates a new future that will immediately resolve successfully to the given value.
use futures_core::future::*;
let future_of_1 = ok::<u32, u32>(1);