reverseRange method
Reverses the elements in a range of the list.
Implementation
void reverseRange(int start, int end) {
RangeError.checkValidRange(start, end, length);
while (start < --end) {
var tmp = this[start];
this[start] = this[end];
this[end] = tmp;
start += 1;
}
}