Skip to content

Commit

Permalink
Fix clippy warnings
Browse files Browse the repository at this point in the history
First modules are disabled for some reason and it is not clear why
Second we replaced .map(Clone::clone) with .cloned()
Last we removed uncessary .into_iter()

Signed-off-by: Ahmed <>
  • Loading branch information
Ahmed committed Jul 4, 2024
1 parent 9839d72 commit 154cced
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
clippy::checked_conversions,
clippy::from_iter_instead_of_collect,
clippy::missing_errors_doc,
clippy::mod_module_files,
clippy::implicit_saturating_sub,
clippy::panic,
clippy::panic_in_result_fn,
Expand Down Expand Up @@ -207,7 +206,7 @@ where
U: Add<N>,
Sum<U, N>: ArraySize,
{
self.into_iter().chain(other.into_iter()).collect()
self.into_iter().chain(other).collect()
}

/// Splits `self` at index `N` in two arrays.
Expand Down Expand Up @@ -766,7 +765,7 @@ where

#[inline]
fn try_from(slice: &'a [T]) -> Result<Array<T, U>, TryFromSliceError> {
<&'a Self>::try_from(slice).map(Clone::clone)
<&'a Self>::try_from(slice).cloned()
}
}

Expand Down

0 comments on commit 154cced

Please sign in to comment.