pub unsafe trait FlatMapInPlaceVec {
type Elem;
// Required methods
fn len(&self) -> usize;
unsafe fn set_len(&mut self, len: usize);
fn as_ptr(&self) -> *const Self::Elem;
fn as_mut_ptr(&mut self) -> *mut Self::Elem;
fn insert(&mut self, idx: usize, elem: Self::Elem);
}Expand description
A vec-like type must implement these operations to support flat_map_in_place.
§Safety
The memory safety of the unsafe block in flat_map_in_place relies on impls of this trait
implementing all the operations correctly.