docs: private void pop(char closer) throws JSONException {
          if (m_top <= -1) {
              throw new JSONException("Nesting error.");
          }
          try {
              m_writer.write(closer);
          }
          catch (IOException e) {
              throw new JSONException(e);
          }
          --m_top;
          m_mode = (m_top == -1) ?
                  'd' :
                  (m_scopeStack[m_top] == null) ? 'a' : 'k';
          m_expectingComma = true;
      }