[Python-3000] Iterators for dict keys, values, and items == annoying :)

Benji York benji at benjiyork.com
Mon Mar 27 14:22:39 CEST 2006


Adam DePrince wrote:
> Question #2: 
> 
> What should delete() return?   I currently have it returning the iter
> itself to make it possible to say:
> 
> value = iter.delete().next()

Python doesn't generally return self for call-chaining purposes.  I'd 
say delete() should return None.
--
Benji York


More information about the Python-3000 mailing list