From 439beab41fb5162b26c075a7d7cb28662ba0ab7b Mon Sep 17 00:00:00 2001 From: varkor Date: Thu, 4 Jan 2018 15:03:50 +0000 Subject: [PATCH] Remove min from RangeFrom --- src/libcore/iter/range.rs | 5 ----- src/libcore/tests/iter.rs | 7 ------- 2 files changed, 12 deletions(-) diff --git a/src/libcore/iter/range.rs b/src/libcore/iter/range.rs index 4aec70a86e0..03cc5a03cff 100644 --- a/src/libcore/iter/range.rs +++ b/src/libcore/iter/range.rs @@ -312,11 +312,6 @@ impl Iterator for ops::RangeFrom { self.start = plus_n.add_one(); Some(plus_n) } - - #[inline] - fn min(self) -> Option { - Some(self.start) - } } #[unstable(feature = "fused", issue = "35602")] diff --git a/src/libcore/tests/iter.rs b/src/libcore/tests/iter.rs index 71a75115d86..c75417f8de9 100644 --- a/src/libcore/tests/iter.rs +++ b/src/libcore/tests/iter.rs @@ -1359,13 +1359,6 @@ fn test_range_max() { assert_eq!((1..1).max(), None); } -#[test] -fn test_range_from_min() { - assert_eq!((0..).min(), Some(0)); - assert_eq!((-20..).min(), Some(-20)); - assert_eq!((20..).min(), Some(20)); -} - #[test] fn test_range_inc_last_max() { assert_eq!((0..=20).last(), Some(20));