7 releases (4 breaking)

0.5.2 Dec 28, 2024
0.5.1 Dec 28, 2024
0.4.0 Dec 27, 2024
0.3.2 Dec 26, 2024
0.1.0 Feb 20, 2024

#667 in Algorithms

Download history 15/week @ 2024-10-03 107/week @ 2024-10-10 105/week @ 2024-10-17 5/week @ 2024-10-24 4/week @ 2024-10-31 23/week @ 2024-11-21 24/week @ 2024-11-28 17/week @ 2024-12-05 21/week @ 2024-12-12 35/week @ 2024-12-19 552/week @ 2024-12-26 38/week @ 2025-01-02 41/week @ 2025-01-09 24/week @ 2025-01-16

655 downloads per month
Used in 2 crates (via folder)

Apache-2.0/MIT

9KB
120 lines

Loop Package Documentation Build

The package allows for processing iterators in parallel.

Examples

Synchronously:

use r#loop::parallelize;

let double = |value| 2 * value;
let _ = parallelize(0..10, double, None).collect::<Vec<_>>();

Asynchronously:

use futures::stream::StreamExt;
use r#loop::asynchronous::parallelize;

let double = |value| async move { 2 * value };
let _ = parallelize(0..10, double, None).collect::<Vec<_>>().await;

Contribution

Your contribution is highly appreciated. Do not hesitate to open an issue or a pull request. Note that any contribution submitted for inclusion in the project will be licensed according to the terms given in LICENSE.md.

Dependencies

~0–5.5MB
~22K SLoC