Trait AsVecIntoIter

pub(crate) unsafe trait AsVecIntoIter

Internal helper trait for in-place iteration specialization.

Currently this is only implemented by vec::IntoIter - returning a reference to itself - and binary_heap::IntoIter which returns a reference to its inner representation.

Since this is an internal trait it hides the implementation detail binary_heap::IntoIter uses vec::IntoIter internally.

Safety

In-place iteration relies on implementation details of vec::IntoIter, most importantly that it does not create references to the whole allocation during iteration, only raw pointers

Associated Types

type Item;

Required Methods

fn as_into_iter(&mut self) -> &mut IntoIter<Self::Item>

Implementors