erase method

void erase(
  1. int index
)

Managed _array__erase with the native overlapping left shift.

Implementation

void erase(int index) {
  RangeError.checkValidIndex(index, this, 'index', _size);
  final tailCount = _size - index - 1;
  if (tailCount > 0) {
    _storage.setRange(index, index + tailCount, _storage, index + 1);
  }
  _storage[--_size] = null;
}