We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7bd13fc commit b5c1242Copy full SHA for b5c1242
src/lib.rs
@@ -1739,6 +1739,8 @@ pub trait Itertools : Iterator {
1739
///
1740
/// let numbers = [1, 2, 3, 4];
1741
/// assert_eq!(numbers.iter().find_or_last(|&&x| x > 5), Some(&4));
1742
+ /// assert_eq!(numbers.iter().find_or_last(|&&x| x > 2), Some(&3));
1743
+ /// assert_eq!(std::iter::empty::<i32>().find_or_last(|&x| x > 5), None);
1744
/// ```
1745
fn find_or_last<P>(mut self, predicate: P) -> Option<Self::Item>
1746
where Self: Sized,
0 commit comments