docs: public void replaceFromToWithFromTo(int from, int to, ObjectArrayList other, int otherFrom, int otherTo) {
  	if (otherFrom>otherTo) {
  		throw new IndexOutOfBoundsException("otherFrom: "+otherFrom+", otherTo: "+otherTo);
  	}
  	if (this==other && to-from!=otherTo-otherFrom) { // avoid stumbling over my own feet
  		replaceFromToWithFromTo(from, to, partFromTo(otherFrom, otherTo), 0, otherTo-otherFrom);
  		return;
  	}
  	
  	int length=otherTo-otherFrom+1;
  	int diff=length;
  	int theLast=from-1;
  
  	//System.out.println("from="+from);
  	//System.out.println("to="+to);
  	//System.out.println("diff="+diff);
  	
  	if (to>=from) {
  		diff -= (to-from+1);
  		theLast=to;
  	}
  	
  	if (diff>0) {
  		beforeInsertDummies(theLast+1, diff);
  	}
  	else {
  		if (diff<0) {
  			removeFromTo(theLast+diff, theLast-1);
  		}
  	}
  
  	if (length>0) {
  		System.arraycopy(other.elements, otherFrom, elements, from, length);
  	}
  }