private void recoverState(int n) {
          TableStack<V> s; int len;
          while ((s = stack) != null && (index += (len = s.length)) >= n) {
              n = len;
              index = s.index;
              tab = s.tab;
              s.tab = null;
              TableStack<V> next = s.next;
              s.next = spare; // save for reuse
              stack = next;
              spare = s;
          }
        if (s == null && (index += baseSize) >= n) {
          index = ++baseIndex;
        }
      }
private void recoverState(int n)