Crates.io | parallel-future |
lib.rs | parallel-future |
version | 6.0.3 |
source | src |
created_at | 2024-04-30 16:09:22.994205 |
updated_at | 2024-05-02 09:54:09.35849 |
description | fluent async task experiments |
homepage | |
repository | https://github.com/yoshuawuyts/parallel-future |
max_upload_size | |
id | 1225207 |
size | 28,564 |
$ cargo add parallel-future
use parallel_future::prelude::*;
use futures_concurrency::prelude::*;
async_std::task::block_on(async {
let a = async { 1 }.par(); // ← returns `ParallelFuture`
let b = async { 2 }.par(); // ← returns `ParallelFuture`
let (a, b) = (a, b).join().await; // ← concurrent `.await`
assert_eq!(a + b, 3);
})
This crate uses #![deny(unsafe_code)]
to ensure everything is implemented in
100% Safe Rust.
Want to join us? Check out our "Contributing" guide and take a look at some of these issues: