mirror of https://github.com/rust-lang/rust.git
Fill tracking issue for `iter_map_while` feature
This commit is contained in:
parent
1aff08010d
commit
db1a107b3f
|
@ -1760,7 +1760,7 @@ where
|
|||
/// [`map_while`]: trait.Iterator.html#method.map_while
|
||||
/// [`Iterator`]: trait.Iterator.html
|
||||
#[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)]
|
||||
pub struct MapWhile<I, P> {
|
||||
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> {
|
||||
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
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>
|
||||
where
|
||||
P: FnMut(I::Item) -> Option<B>,
|
||||
|
|
|
@ -351,7 +351,7 @@ pub use self::adapters::Cloned;
|
|||
pub use self::adapters::Copied;
|
||||
#[stable(feature = "iterator_flatten", since = "1.29.0")]
|
||||
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;
|
||||
#[stable(feature = "iterator_step_by", since = "1.28.0")]
|
||||
pub use self::adapters::StepBy;
|
||||
|
|
|
@ -1117,7 +1117,7 @@ pub trait Iterator {
|
|||
/// [`Some`]: ../../std/option/enum.Option.html#variant.Some
|
||||
/// [`None`]: ../../std/option/enum.Option.html#variant.None
|
||||
#[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>
|
||||
where
|
||||
Self: Sized,
|
||||
|
|
Loading…
Reference in New Issue