next method

Token? next()

Returns the current token, and scans the next one.

Implementation

Token? next() {
  Token? t = token;
  endOffset = t?.endOffset?? 0;
  token = lexer?.scan();
  return t;
}