pub trait First<A>: Sized + Compound<A> {
    fn first(&self) -> Option<Branch<'_, Self, A>>;
    fn first_mut(&mut self) -> Option<BranchMut<'_, Self, A>>
    where
        Self: MutableLeaves
; }
Expand description

Trait that provides a first and first_mut method to any Compound.

Required Methods

Construct a Branch pointing to the first element, if not empty

Construct a BranchMut pointing to the first element, if not empty

Implementors