Skip to content

Commit fe3a1e9

Browse files
committed
clippy
1 parent 2707969 commit fe3a1e9

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

crates/whir/src/matrix.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -251,11 +251,7 @@ impl<T: Clone + Send + Sync, S: DenseStorage<T>> Matrix<T> for DenseMatrix<T, S>
251251

252252
#[inline]
253253
fn height(&self) -> usize {
254-
if self.width == 0 {
255-
0
256-
} else {
257-
self.values.borrow().len() / self.width
258-
}
254+
self.values.borrow().len().checked_div(self.width).unwrap_or(0)
259255
}
260256

261257
#[inline]

0 commit comments

Comments
 (0)