diff --git a/src/sum/ifastsum.rs b/src/sum/ifastsum.rs index 5814034b..38bdf837 100644 --- a/src/sum/ifastsum.rs +++ b/src/sum/ifastsum.rs @@ -67,7 +67,7 @@ where // Step 3(2)(b)(i) // The following addition is guaranteed not to overflow, because: - debug_assert!(count < usize::max_value()); + debug_assert!(count < usize::MAX); // and thus: debug_assert!(count.checked_add(1).is_some()); count += 1; @@ -91,7 +91,7 @@ where *xs.get_unchecked_mut(count) = st; } // The following addition is guaranteed not to overflow, because: - debug_assert!(count < usize::max_value()); + debug_assert!(count < usize::MAX); // and thus: debug_assert!(count.checked_add(1).is_some()); *n = count + 1; diff --git a/src/sum/onlineexactsum.rs b/src/sum/onlineexactsum.rs index c2042092..f43d4400 100644 --- a/src/sum/onlineexactsum.rs +++ b/src/sum/onlineexactsum.rs @@ -166,7 +166,7 @@ where // this point): debug_assert!(self.i < F::base_pow_significand_digits_half()); // and (for `f32` and `f64`) we have: - debug_assert!(F::base_pow_significand_digits_half() < usize::max_value()); + debug_assert!(F::base_pow_significand_digits_half() < usize::MAX); // thus we can assume: debug_assert!(self.i.checked_add(1).is_some()); self.i += 1;