Skip to content

Commit

Permalink
fix(style): use usize::midpoint when appropriate
Browse files Browse the repository at this point in the history
  • Loading branch information
samueltardieu committed Dec 29, 2024
1 parent 9960e34 commit 9460618
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/matrix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@ impl<C> Matrix<C> {
2 => self.data.reverse(),
n => {
for r in 0..self.rows / 2 {
for c in 0..(self.columns + 1) / 2 {
for c in 0..usize::midpoint(1, self.columns) {
// i1 … i2
// … … …
// i4 … i3
Expand Down

0 comments on commit 9460618

Please sign in to comment.