Fill tracking issue for `iter_map_while` feature

This commit is contained in:
Waffle 2020-01-25 21:23:22 +03:00
parent 1aff08010d
commit db1a107b3f
3 changed files with 5 additions and 5 deletions

View File

@ -1760,7 +1760,7 @@ where
/// [`map_while`]: trait.Iterator.html#method.map_while /// [`map_while`]: trait.Iterator.html#method.map_while
/// [`Iterator`]: trait.Iterator.html /// [`Iterator`]: trait.Iterator.html
#[must_use = "iterators are lazy and do nothing unless consumed"] #[must_use = "iterators are lazy and do nothing unless consumed"]
#[unstable(feature = "iter_map_while", reason = "recently added", issue = "none")] #[unstable(feature = "iter_map_while", reason = "recently added", issue = "68537")]
#[derive(Clone)] #[derive(Clone)]
pub struct MapWhile<I, P> { pub struct MapWhile<I, P> {
iter: I, iter: I,
@ -1774,14 +1774,14 @@ impl<I, P> MapWhile<I, P> {
} }
} }
#[unstable(feature = "iter_map_while", reason = "recently added", issue = "none")] #[unstable(feature = "iter_map_while", reason = "recently added", issue = "68537")]
impl<I: fmt::Debug, P> fmt::Debug for MapWhile<I, P> { impl<I: fmt::Debug, P> fmt::Debug for MapWhile<I, P> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
f.debug_struct("MapWhile").field("iter", &self.iter).field("flag", &self.finished).finish() f.debug_struct("MapWhile").field("iter", &self.iter).field("flag", &self.finished).finish()
} }
} }
#[unstable(feature = "iter_map_while", reason = "recently added", issue = "none")] #[unstable(feature = "iter_map_while", reason = "recently added", issue = "68537")]
impl<B, I: Iterator, P> Iterator for MapWhile<I, P> impl<B, I: Iterator, P> Iterator for MapWhile<I, P>
where where
P: FnMut(I::Item) -> Option<B>, P: FnMut(I::Item) -> Option<B>,

View File

@ -351,7 +351,7 @@ pub use self::adapters::Cloned;
pub use self::adapters::Copied; pub use self::adapters::Copied;
#[stable(feature = "iterator_flatten", since = "1.29.0")] #[stable(feature = "iterator_flatten", since = "1.29.0")]
pub use self::adapters::Flatten; pub use self::adapters::Flatten;
#[unstable(feature = "iter_map_while", reason = "recently added", issue = "none")] #[unstable(feature = "iter_map_while", reason = "recently added", issue = "68537")]
pub use self::adapters::MapWhile; pub use self::adapters::MapWhile;
#[stable(feature = "iterator_step_by", since = "1.28.0")] #[stable(feature = "iterator_step_by", since = "1.28.0")]
pub use self::adapters::StepBy; pub use self::adapters::StepBy;

View File

@ -1117,7 +1117,7 @@ pub trait Iterator {
/// [`Some`]: ../../std/option/enum.Option.html#variant.Some /// [`Some`]: ../../std/option/enum.Option.html#variant.Some
/// [`None`]: ../../std/option/enum.Option.html#variant.None /// [`None`]: ../../std/option/enum.Option.html#variant.None
#[inline] #[inline]
#[unstable(feature = "iter_map_while", reason = "recently added", issue = "none")] #[unstable(feature = "iter_map_while", reason = "recently added", issue = "68537")]
fn map_while<B, P>(self, predicate: P) -> MapWhile<Self, P> fn map_while<B, P>(self, predicate: P) -> MapWhile<Self, P>
where where
Self: Sized, Self: Sized,