Expand description
This module provides different helpers in creating constant sized arrays and converting them to different formats.
Functions in this module are not necessarily optimal in terms of allocations, as they tend to create intermediate vectors. For better performance, either optimise this code, or use (non-fixed-sized) vectors.
Functions
- Converts a vector of elements to a boxed one. Semantically equivalent to
vector.into_boxed_slice().try_into().unwrap()
. - Converts a two-dimensional vector to a constant sized two-dimensional array.
- Converts a three-dimensional vector to a constant sized two-dimensional array.