Skip to content

Commit 9a6f8b6

Browse files
committed
Following clippy lints
1 parent 3e5d02d commit 9a6f8b6

File tree

2 files changed

+3
-9
lines changed

2 files changed

+3
-9
lines changed

src/slice.rs

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -110,18 +110,12 @@ copy_and_clone! {SliceOrIndex}
110110
impl SliceOrIndex {
111111
/// Returns `true` if `self` is a `Slice` value.
112112
pub fn is_slice(&self) -> bool {
113-
match self {
114-
SliceOrIndex::Slice { .. } => true,
115-
_ => false,
116-
}
113+
matches!(self, SliceOrIndex::Slice { .. })
117114
}
118115

119116
/// Returns `true` if `self` is an `Index` value.
120117
pub fn is_index(&self) -> bool {
121-
match self {
122-
SliceOrIndex::Index(_) => true,
123-
_ => false,
124-
}
118+
matches!(self, SliceOrIndex::Index(_))
125119
}
126120

127121
/// Returns a new `SliceOrIndex` with the given step size (multiplied with

src/stacking.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ where
165165
let mut res = Array::from_shape_vec(res_dim, v)?;
166166

167167
res.axis_iter_mut(axis)
168-
.zip(arrays.into_iter())
168+
.zip(arrays.iter())
169169
.for_each(|(mut assign_view, array)| {
170170
assign_view.assign(&array);
171171
});

0 commit comments

Comments
 (0)