copyFromSlice method

void copyFromSlice(
  1. Slice<T> src
)

Copies the elements from src into self. The length of src must be the same as self.

Implementation

void copyFromSlice(Slice<T> src) {
  for (var i = src._start, j = _start; i < src._end && j < _end; i++, j++) {
    _list[j] = src._list[i];
  }
}