docs: private boolean readNextLine() throws IOException {
          boolean newLine = false;
          if (bufferLimit > 0 && !bufferLineEnd) {
              // check for "last line"
              if (bufferLimit < buffer.length) {
                  return false;
              }
          } else {
              newLine = true;
          }
  
          bufferLineEnd = false;
  
          int off = 0;
          char[] b = new char[1];
          while (off < buffer.length && reader.read(b, 0, 1) > 0) {
              final char ch = b[0];
              buffer[off] = ch;
              ++off;
              if (ch == '\n') {
                  bufferLineEnd = true;
                  break;
              }
          }
          if (off > 0) {
              if (newLine) {
                  ++lineNo;
                  linePos = 0;
              }
              if (off < buffer.length) {
                  buffer[off] = 0;
              }
              bufferOffset = -1;
              bufferLimit = off;
              return true;
          }
          return false;
      }