()
| 485 | |
| 486 | /// JIT optimization |
| 487 | private void growByOne() { |
| 488 | int adding = 0; |
| 489 | if (capacityIncrement <= 0) { |
| 490 | if ((adding = elementData.length) == 0) { |
| 491 | adding = 1; |
| 492 | } |
| 493 | } else { |
| 494 | adding = capacityIncrement; |
| 495 | } |
| 496 | |
| 497 | E[] newData = newElementArray(elementData.length + adding); |
| 498 | System.arraycopy(elementData, 0, newData, 0, elementCount); |
| 499 | elementData = newData; |
| 500 | } |
| 501 | |
| 502 | private void growBy(int required) { |
| 503 | int adding = 0; |
no test coverage detected