Crates.io | collect_array |
lib.rs | collect_array |
version | 0.1.3 |
source | src |
created_at | 2021-04-06 21:22:34.801443 |
updated_at | 2021-06-09 23:34:21.780468 |
description | Allows for collecting an Iterator into an exactly sized array. |
homepage | |
repository | https://github.com/illicitonion/collect_array |
max_upload_size | |
id | 380014 |
size | 18,946 |
Allows for collecting an Iterator into an exactly sized array.
use collect_array::CollectArrayResult;
let result: CollectArrayResult<_, 2> = vec![1, 2].into_iter().collect();
assert_eq!(CollectArrayResult::Ok([1, 2]), result);