Status of PEP's?

James_Althoff at i2.com James_Althoff at i2.com
Tue Mar 5 15:55:29 EST 2002


[James_Althoff]
> Just keep in mind that indici/indices/indexes-type proposals don't
> help in cases where __len__ is not defined.  Two-dimensional
> structures, for example.

[Greg Ewing]
> It does if we define an __indices__ protocol to
> go with it. First look for __indices__, then fall
> back on __len__.

Again, the key point that I was trying to illustrate is that with the
expanding world of Python (a very good thing, right?) -- into the realm of
Java API's via Jython, for example -- it is not going to be possible to
just insist that every class that one deals with be fixed to obey some new
protocol.  The various kinds of tables one deals with in Java via Jython,
for example.

Jim





More information about the Python-list mailing list