eat

abstract fun eat(): Token<T>

Eats the current token, advancing the index by one.

abstract fun eat(type: T): Token<T>

Eats the current token, advancing the index by one. Throws a SyntaxException if the token type doesn't match.