Crate arrays

Source
Expand description

Construct an array from an iterator and other helpers.

§Getting started

Add the arrays crate to your Cargo manifest.

cargo add arrays

Now get the next N items from an iterator.

let arr: [_; 3] = arrays::from_iter(iter).unwrap();

Structs§

IntoIter
A by-value array iterator.

Functions§

from_iter
Consumes N elements from the iterator and returns them as an array. If the iterator yields fewer than N items, Err is returned containing the already yielded items.
from_iter_unchecked
Consumes N elements from the iterator and returns them as an array.