expressionStatement method

AstNode expressionStatement()

Implementation

AstNode expressionStatement() {
  AstNode expr = expression();
  consume(TokenType.semicolon, "Expect ';' after expression.");
  return ExpressionStatement(expr);
}