@@ -116,12 +116,12 @@ mod not_parallel {
116116pub use not_parallel:: { build_thread, in_parallel_with_slice, join, threads, Scope } ;
117117
118118/// Read items from `input` and `consume` them in a single thread, producing an output to be collected by a `reducer`,
119- /// whose task is to aggregate these outputs into the final result returned by this function.
119+ /// whose task it is to aggregate these outputs into the final result returned by this function.
120120///
121- /// * `new_thread_state(thread_number) -> State` produces thread-local state once per thread to be based to `consume`
121+ /// * `new_thread_state(thread_number) -> State` produces thread-local state once per thread to be passed to `consume`
122122/// * `consume(Item, &mut State) -> Output` produces an output given an input along with mutable state.
123123/// * For `reducer`, see the [`Reduce`] trait
124- /// * if `thread_limit` has no effect as everything is run on the main thread, but is present to keep the signature
124+ /// * `thread_limit` has no effect as everything is run on the main thread, but is present to keep the signature
125125/// similar to the parallel version.
126126///
127127/// **This serial version performing all calculations on the current thread.**
@@ -143,12 +143,12 @@ where
143143}
144144
145145/// Read items from `input` and `consume` them in multiple threads,
146- /// whose output output is collected by a `reducer`. Its task is to
146+ /// whose output is collected by a `reducer`. Its task is to
147147/// aggregate these outputs into the final result returned by this function with the benefit of not having to be thread-safe.
148- /// Caall `finalize` to finish the computation, once per thread, if there was no error sending results earlier.
148+ /// Call `finalize` to finish the computation, once per thread, if there was no error sending results earlier.
149149///
150- /// * if `thread_limit` is `Some`, the given amount of threads will be used. If `None`, all logical cores will be used.
151- /// * `new_thread_state(thread_number) -> State` produces thread-local state once per thread to be based to `consume`
150+ /// * if `thread_limit` is `Some`, the given number of threads will be used. If `None`, all logical cores will be used.
151+ /// * `new_thread_state(thread_number) -> State` produces thread-local state once per thread to be passed to `consume`
152152/// * `consume(Item, &mut State) -> Output` produces an output given an input obtained by `input` along with mutable state initially
153153/// created by `new_thread_state(…)`.
154154/// * `finalize(State) -> Output` is called to potentially process remaining work that was placed in `State`.
0 commit comments