code: @Nullable
      public Token next() throws IOException {
          if (unreadToken != null) {
              lastToken = unreadToken;
              unreadToken = null;
              return lastToken;
          }
  
          while (lastChar >= 0) {
              if (lastChar == 0) {
                  if (!readNextChar()) {
                      break;
                  }
              }
              if (lastChar == Token.kNewLine ||
                  lastChar == Token.kCarriageReturn ||
                  lastChar == Token.kSpace ||
                  lastChar == Token.kTab) {
                  lastChar = 0;
                  continue;
              }
  
              if (lastChar == Token.kShellComment) {
                  getRestOfLine();
                  continue;
              }
  
              if (lastChar == Token.kLiteralDoubleQuote || lastChar == Token.kLiteralQuote) {
                  lastToken = nextStringLiteral((char) lastChar);
                  return lastToken;
              } else if (lastChar == '.' || lastChar == '-' || (lastChar >= '0' && lastChar <= '9')) {
                  lastToken = nextNumber();
                  return lastToken;
              } else if ('_' == lastChar ||
                         ('a' <= lastChar && lastChar <= 'z') ||
                         ('A' <= lastChar && lastChar <= 'Z')) {
                  lastToken = nextToken();
                  return lastToken;
              } else if (lastChar < 0x20 || lastChar >= 0x7F) {
                  // non-ASCII UTF-8 characters are only allowed inside JSON string literals.
                  throw failure(lineNo, linePos, 1, "Unknown token initiator '%s'", Strings.escape((char) lastChar));
              } else {
                  lastToken = nextSymbol();
                  return lastToken;
              }
          }
  
          return null;
      }
docs: Returns the next token on the stream, or null if there are no more JSON
  tokens on the stream.
  @return The next token, or null.
  @throws IOException If unable to read from stream.