Skip to content

Commit c451cf1

Browse files
authored
Fix is_empty method logic in matrix.rs
1 parent 70212c7 commit c451cf1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/linalg/basic/matrix.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ impl<T: Debug + Display + Copy + Sized> Array<T, (usize, usize)> for DenseMatrix
385385
}
386386

387387
fn is_empty(&self) -> bool {
388-
self.ncols > 0 && self.nrows > 0
388+
self.ncols < 1 || self.nrows < 1
389389
}
390390

391391
fn iterator<'b>(&'b self, axis: u8) -> Box<dyn Iterator<Item = &'b T> + 'b> {

0 commit comments

Comments
 (0)