public void Eat(TokenType tokenType) { if (m_CurrentToken.tokenType == tokenType) { m_CurrentToken = m_Lexer.GetNextToken(); } else { InvokeError(); } }
public Interpreter(Lexer lexer) { m_Lexer = lexer; m_CurrentToken = m_Lexer.GetNextToken(); }
public Parser(Lexer lexer) { m_Lexer = lexer; m_CurrentToken = m_Lexer.GetNextToken(); }