#async #futures

nightly futures_future

The Rust crate that converts the old style futures crate futures::Future into the new nightly async/await style std::future::Future so you can easily try out the new syntax

1 unstable release

0.1.0 Sep 11, 2018

#90 in #futures

Download history 12/week @ 2018-09-12

4 downloads per month

MIT license

3KB

Futures Future

The Rust crate that converts the old style futures crate futures::Future into the new nightly async/await style std::future::Future so you can easily try out the new syntax.

Example

#![feature(async_await)]
#![feature(futures_api)]
#![feature(await_macro)]

use futures::*;
use futures::sync::oneshot;
use futures_future::*;

pub async fn and_its_done() {
    let (signal_setup_done, mut setup_done) = oneshot::channel::<bool>();
    let _ = signal_setup_done.send(true);
    let f = futures_future(&mut setup_done);
    await!(f);
}

Dependencies

~465KB