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.
RepeatN::rfold
1 parent 7c5a5c0 commit db0311cCopy full SHA for db0311c
src/repeatn.rs
@@ -68,6 +68,14 @@ where
68
fn next_back(&mut self) -> Option<Self::Item> {
69
self.next()
70
}
71
+
72
+ #[inline]
73
+ fn rfold<B, F>(self, init: B, f: F) -> B
74
+ where
75
+ F: FnMut(B, Self::Item) -> B,
76
+ {
77
+ self.fold(init, f)
78
+ }
79
80
81
impl<A> ExactSizeIterator for RepeatN<A> where A: Clone {}
0 commit comments