]> git.lizzy.rs Git - rust.git/blobdiff - src/test/ui/iterators/iter-count-overflow-debug.rs
Update tests to remove old numeric constants
[rust.git] / src / test / ui / iterators / iter-count-overflow-debug.rs
index d6612035750836e49accc865a8f2d05dcaeb35b3..5a0394ae760e9305c179ab6b1758980785a9e8ec 100644 (file)
@@ -4,13 +4,12 @@
 // compile-flags: -C debug_assertions=yes -C opt-level=3
 
 use std::panic;
-use std::usize::MAX;
 
 fn main() {
-    assert_eq!((0..MAX).by_ref().count(), MAX);
+    assert_eq!((0..usize::MAX).by_ref().count(), usize::MAX);
 
     let r = panic::catch_unwind(|| {
-        (0..=MAX).by_ref().count()
+        (0..=usize::MAX).by_ref().count()
     });
     assert!(r.is_err());
 }