[Python-Dev] Re: PEP 322: Reverse Iteration

Raymond Hettinger python at rcn.com
Wed Nov 5 16:22:35 EST 2003

> >The __reversed__ protocol muddles the issue by inviting to
> > try to make reversed() work for some iterators

The invitation is to add efficient reverse iteration support to regular
objects and user defined classes, not for iterators.  Though I won't be
suprised if someone tries, the only iterator that has a chance with this
is enumerate, but that is not what the hook is for.


More information about the Python-Dev mailing list