minor: use minicore
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
//! option:
|
||||
//! result:
|
||||
//! iterator: option
|
||||
//! iterators: iterator
|
||||
//! iterators: iterator, fn
|
||||
//! default: sized
|
||||
//! clone: sized
|
||||
//! copy: clone
|
||||
@@ -390,7 +390,6 @@ pub mod iter {
|
||||
iter: I,
|
||||
n: usize,
|
||||
}
|
||||
|
||||
impl<I> Iterator for Take<I>
|
||||
where
|
||||
I: Iterator,
|
||||
@@ -401,6 +400,22 @@ pub mod iter {
|
||||
loop {}
|
||||
}
|
||||
}
|
||||
|
||||
pub struct FilterMap<I, F> {
|
||||
iter: I,
|
||||
f: F,
|
||||
}
|
||||
impl<B, I: Iterator, F> Iterator for FilterMap<I, F>
|
||||
where
|
||||
F: FnMut(I::Item) -> Option<B>,
|
||||
{
|
||||
type Item = B;
|
||||
|
||||
#[inline]
|
||||
fn next(&mut self) -> Option<B> {
|
||||
loop {}
|
||||
}
|
||||
}
|
||||
}
|
||||
pub use self::adapters::Take;
|
||||
|
||||
@@ -448,6 +463,13 @@ pub mod iter {
|
||||
fn take(self, n: usize) -> crate::iter::Take<Self> {
|
||||
loop {}
|
||||
}
|
||||
fn filter_map<B, F>(self, f: F) -> crate::iter::FilterMap<Self, F>
|
||||
where
|
||||
Self: Sized,
|
||||
F: FnMut(Self::Item) -> Option<B>,
|
||||
{
|
||||
loop {}
|
||||
}
|
||||
// endregion:iterators
|
||||
}
|
||||
impl<I: Iterator + ?Sized> Iterator for &mut I {
|
||||
|
||||
Reference in New Issue
Block a user