Debian Codegraph @

third_party/rust/indexmap/src/rayon/mod.rs

raw
1 #![cfg_attr(docsrs, doc(cfg(feature = "rayon")))]
2
3 use rayon::prelude::*;
4
5 use alloc::collections::LinkedList;
6
7 use crate::vec::Vec;
8
9 pub mod map;
10 pub mod set;
11
12 // This form of intermediate collection is also how Rayon collects `HashMap`.
13 // Note that the order will also be preserved!
14 fn collect<I: IntoParallelIterator>(iter: I) -> LinkedList<Vec<I::Item>> {
15 iter.into_par_iter().collect_vec_list()
16 }