• Name: (fill me in: name-of-design)
  • Proposed by: [@name](link to github profile)
  • Original proposal (optional): (url)

Design

base (reference)


#![allow(unused)]
fn main() {
/// A trimmed-down version of the `std::Iterator` trait.
pub trait Iterator {
    type Item;
    fn next(&mut self) -> Option<Self::Item>;
    fn size_hint(&self) -> (usize, Option<usize>);
}

/// An adaptation of `Iterator::find` to a free-function
pub fn find<I, T, P>(iter: &mut I, predicate: P) -> Option<T>
where
    I: Iterator<Item = T> + Sized,
    P: FnMut(&T) -> bool;
}

always async


#![allow(unused)]
fn main() {
// fill me in
}

maybe async


#![allow(unused)]
fn main() {
// fill me in
}

generic over all modifier keywords


#![allow(unused)]
fn main() {
// fill me in
}

Notes