Skip to main content

flatten_vector_elements

Function flatten_vector_elements 

Source
pub fn flatten_vector_elements<T, const N: usize>(source: Vec<[T; N]>) -> Vec<T>
Expand description

Transmutes a vector of n arrays each of length N, into a vector of N * n elements.

This function just re-interprets the underlying memory and is thus zero-copy.