Mike Samuel wrote:
> Proxy based iterators work well with existing loop constructs though
> while ('next' in iterator) doSomething(iterator.next);
I don't understand what advantage this has over
while (iterator.hasNext()) doSomething(iterator.next());
If next() has side-effects (moving to the next element), it shouldn't
be a getter.
--
David-Sarah Hopwood ⚥ http://davidsarah.livejournal.com
signature.asc
Description: OpenPGP digital signature
_______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

