// Pops the value off the stack and appends it into the parent fork.  Called
// when leaving a node (either leaf or fork).
Pops the value off the stack and appends it into the parent fork.  Called
when leaving a node (either leaf or fork).
Pops the value off the stack and appends it into the parent fork . Called when leaving a node ( either leaf or fork ) .
fn link_top_value_to_parent(&mut self) {
        assert_eq!(self.label_stack.len() + 1, self.value_stack.len());
        let label = match self.label_stack.pop() {
            Some(l) => l,
            None => return,
        };
        let entry = self.value_stack.pop().expect("unbalanced tree traversal");
        if let LabeledTree::SubTree(ref mut map) =
            self.value_stack.last_mut().expect("label without a root")
        {
            map.try_append(label, entry).unwrap();
        }
    }
fn link_top_value_to_parent ( & mut self ) { assert_eq ! ( self label_stack len ( ) 1 self value_stack len ( ) ) ; let label = match self . label_stack . pop ( ) { Some ( l ) => l , None => return , } ; let entry = self . value_stack . pop ( ) . expect ( " " ) ; if let LabeledTree :: SubTree ( ref mut map ) = self . value_stack . last_mut ( ) . expect ( " " ) { map . try_append ( label , entry ) . unwrap ( ) ; } }
Pops the value off the stack and appends it into the parent fork.
Pops the value off the stack and appends it into the parent fork .
&mut self