PDepend\Source\Language\PHP\AbstractPHPParser::parseExpression PHP Method

parseExpression() private method

This method parses an expression node and returns it. When no expression was found this method will throw an InvalidStateException.
Since: 1.0.1
private parseExpression ( ) : PDepend\Source\AST\ASTNode
return PDepend\Source\AST\ASTNode
    private function parseExpression()
    {
        if (null === ($expr = $this->parseOptionalExpression())) {
            $token = $this->consumeToken($this->tokenizer->peek());
            throw new InvalidStateException($token->startLine, $this->compilationUnit->getFileName(), 'Mandatory expression expected.');
        }
        return $expr;
    }
AbstractPHPParser