finishNumberExtra method

Token finishNumberExtra(
  1. int kind
)

Implementation

Token finishNumberExtra(int kind) {
  if (_maybeEatChar(101 /*e*/) || _maybeEatChar(69 /*E*/)) {
    kind = TokenKind.DOUBLE;
    _maybeEatChar(TokenKind.MINUS);
    _maybeEatChar(TokenKind.PLUS);
    eatDigits();
  }
  if (_peekChar() != 0 && TokenizerHelpers.isIdentifierStart(_peekChar())) {
    _nextChar();
    return _errorToken('illegal character in number');
  }

  return _finishToken(kind);
}