Trait odds::vec::VecFindRemove [] [src]

pub trait VecFindRemove {
    type Item;
    fn find_remove<U>(&mut self, elt: &U) -> Option<(usize, Self::Item)>
    where
        Self::Item: PartialEq<U>
; fn rfind_remove<U>(&mut self, elt: &U) -> Option<(usize, Self::Item)>
    where
        Self::Item: PartialEq<U>
; }

Associated Types

Required Methods

Linear search for the first element equal to elt and remove it if found.

Return its index and the value itself.

Linear search for the last element equal to elt and remove it if found.

Return its index and the value itself.

Implementors