A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-July/026349.html below:

[Python-Dev] Single- vs. Multi-pass iterability

[Python-Dev] Single- vs. Multi-pass iterability [Python-Dev] Single- vs. Multi-pass iterabilityBarry A. Warsaw barry@zope.com
Fri, 12 Jul 2002 11:48:57 -0400
>>>>> "AK" == Andrew Koenig <ark@research.att.com> writes:

    AK> You are assuming that you still have access to the original
    AK> iterable object.  But what if all you have is an iterator?
    AK> Then you need to be able to ask the iterator for a new
    AK> iterator.

Would it be useful to add to the interator "interface" a method which
would retrieve the original iterable object?  I've no idea what that
method should be called, but it seems like it would be trivial to add
since most (all?) iterators have a pointer to their underlying object
anyway, don't they?

-Barry




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4