mirror of
https://github.com/Noratrieb/advent-of-code.git
synced 2026-01-14 09:35:01 +01:00
remove safety
This commit is contained in:
parent
96a3f6da2c
commit
c078d27255
1 changed files with 0 additions and 2 deletions
|
|
@ -42,7 +42,6 @@ pub trait IteratorExt: Iterator {
|
|||
where
|
||||
Self::Item: Default + Copy,
|
||||
{
|
||||
// SAFETY: Uninit is valid for MaybeUninit
|
||||
let mut array: [Self::Item; N] = [Default::default(); N];
|
||||
|
||||
for i in 0..array.len() {
|
||||
|
|
@ -56,7 +55,6 @@ pub trait IteratorExt: Iterator {
|
|||
return Err(CollectArrayError);
|
||||
}
|
||||
|
||||
// SAFETY: All elements have been initialized
|
||||
Ok(array)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue