[−][src]Function futures_util::future::ready
ⓘImportant traits for Ready<T>
pub fn ready<T>(t: T) -> Ready<T>
Create a future that is immediately ready with a value.
Examples
#![feature(async_await, await_macro, futures_api)] use futures::future; let a = future::ready(1); assert_eq!(await!(a), 1);