eq<U> method
Determines if the elements of this Iterator are equal to those of another using "==".
Implementation
@override
bool eq<U>(Iterator<U> other) {
while (true) {
if (moveNext()) {
if (other.moveNext()) {
if (current != other.current) {
return false;
}
} else {
return false;
}
} else {
if (other.moveNext()) {
return false;
}
return true;
}
}
}