How do you refer to an iterator in docs?

Evan Driscoll driscoll at cs.wisc.edu
Sat Apr 21 00:24:13 EDT 2012


On 4/20/2012 22:01, Roy Smith wrote:
> A basket of apples is a basket which contains apples, in the same way a 
> list contains foos.  But an iterator doesn't contain anything.  You 
> wouldn't say, "a spigot of water", because the spigot isn't a container 
> holding the water.  It is simply a mechanism for delivering the water in 
> a controlled way.

You would, however, say "water spigot". If you apply that analogy, maybe
"Foo iterator" is reasonable. (I didn't read the whole thread so maybe
someone suggested this already, or dismissed it.)

Personally though, I'd probably say an iterator *to* Foos.

Evan

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 552 bytes
Desc: OpenPGP digital signature
URL: <http://mail.python.org/pipermail/python-list/attachments/20120420/bb62cae6/attachment-0001.sig>


More information about the Python-list mailing list