private function match(int $type)
    {
        if (! $this->lexer->isNextToken($type)) {
            $this->syntaxError();
        }

        $value = $this->lexer->lookahead['value'];
        $this->lexer->moveNext();

        return $value;
    }
private function match(int $type)
    {
        if (! $this->lexer->isNextToken($type)) {
            $this->syntaxError();
        }

        $value = $this->lexer->lookahead['value'];
        $this->lexer->moveNext();

        return $value;
    }
private function match ( int $ type ) { if ( ! $ this -> lexer -> isNextToken ( $ type ) ) { $ this -> syntaxError ( ) ; } $ value = $ this -> lexer -> lookahead [ 'value' ] ; $ this -> lexer -> moveNext ( ) ; return $ value ; }
Match a token in the lexer.

@param int $type

@return mixed

@throws SyntaxErrorException
Match a token in the lexer .