repeat_with

Function repeat_with 

Source
pub const fn repeat_with<T, F: FnMut() -> T>(function: F) -> RepeatWith<F>
Expand description

Creates RepeatWith<F> non-empty iterator that repeats items computed from the given function endlessly.