src/endobox/Box.php
public function head() : Box
    {
        // keep track of visited boxes for cycle detection
        $touched = [];
        for ($b = $this; $b->prev !== null; $b = $b->visit($touched)->prev);
        return $b;
    }
public function head() : Box
    {
        // keep track of visited boxes for cycle detection
        $touched = [];
        for ($b = $this; $b->prev !== null; $b = $b->visit($touched)->prev);
        return $b;
    }
public function head ( ) : Box { // keep track of visited boxes for cycle detection $ touched = [ ] ; for ( $ b = $ this ; $ b -> prev !== null ; $ b = $ b -> visit ( $ touched ) -> prev ) ; return $ b ; }
Return the head of the list.
Return the head of the list .