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/026843.html below:

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

[Python-Dev] Single- vs. Multi-pass iterability [Python-Dev] Single- vs. Multi-pass iterabilityKa-Ping Yee ping@zesty.ca
Sat, 20 Jul 2002 05:58:39 -0700 (PDT)
On Fri, 19 Jul 2002, Tim Peters wrote:
> "for" did and does work in accord with a simple protocol, and whether that's
> "destructive" depends on how the specific objects involved implement their
> pieces of the protocol, not on the protocol itself.  The same is true of all
> of Python's hookable protocols.

Name any protocol for which the question "does this mutate?" has no answer.

(I ask you to accept that __call__ is a special case.)

> What's so special about "for" that it
> should pretend to deliver purely functional behavior in a highly
> non-functional language?

Who said anything about functional behaviour?  I'm not requiring that
looping *never* mutate.  I just want to be able to tell *whether* it will.


-- ?!ng





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