pub trait FlatMapInPlace<T> {
// Required method
fn flat_map_in_place<F, I>(&mut self, f: F)
where F: FnMut(T) -> I,
I: IntoIterator<Item = T>;
}Required Methods§
Sourcefn flat_map_in_place<F, I>(&mut self, f: F)where
F: FnMut(T) -> I,
I: IntoIterator<Item = T>,
fn flat_map_in_place<F, I>(&mut self, f: F)where
F: FnMut(T) -> I,
I: IntoIterator<Item = T>,
f turns each element into 0..many elements. This function will consume the existing
elements in a vec-like structure and replace them with any number of new elements — fewer,
more, or the same number — as efficiently as possible.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.