//! Parallelism helper — the single place the `parallel`/serial split lives.
//!
//! With the default `parallel` feature this dispatches to rayon over the
//! independent sample axis: each sample's spillover NNLS is solved on its own
//! unit of work. With `--no-default-features` it is a plain serial loop and the
//! crate pulls no parallelism dependency. (The ssGSEA enrichment stage
//! parallelizes inside `gsva` via the forwarded `gsva-rust/parallel` feature.)
//!
//! The parallel axis only ever reorders *independent* units of work — each
//! sample's NNLS is deterministic and self-contained, and results are written
//! back in index order — so the output is **bit-identical** to the serial build
//! and to R, never an approximation.
/// Map `f` over `0..n`, returning the results in index order.
///
/// Parallel over the range when the `parallel` feature is enabled; otherwise a
/// serial `map().collect()`.
pub
/// Map `f` over `0..n`, returning the results in index order (serial fallback).
pub