From: "Alex Martelli" <aleax@aleax.it> > PEP 246 cannot in any way impede "something" (or more likely "somebody") from > writing inappropriate or totally incorrect code, nor will it even try. Maybe > I'm missing your point...? Maybe, or maybe not. I guess if the reiterable sequence adapter says "list(x)", nobody should be using it to find out whether a thing is reiterable. Or maybe the reiterable sequence adapter shouldn't say "list(x)" because that's destructive -- though that begs the question of finding out whether x is reiterable. Maybe the PEP is just a red herring as far as the iterator problem is concerned. As long as the language has built-in facilities like 'for' and 'in' which use iteration protocols at the core of the language, re-iterability ought to be expressible likewise, in core language terms, regardless of the more-extensible mechanisms of PEP 246. whole-pile-of-maybes-ly y'rs, dave
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