On Wed, 2005-11-30 at 14:36 -0500, Edward Loper wrote: > There's no need to change the iterator protocol for your example use > case; you could just define a simple iterator-wrapper:
Good point. Perhaps it would be a useful addition to the itertools module then? itertools.interruptable(iterable) Matthew Barnes _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com