Steven Bethard wrote: > Unfortunately, I don't think __getslice__ can be removed from list (and > str and tuple) because of backwards compatibility constraints...
Wouldn't it work to have __getslice__ call __getitem__? And, since that would be too much of a performance hit, have it check whether its type is list (or str or tuple), and only call __getitem__ if it is not (i.e., only for subclasses). I don't think that would be too bad. Subclasses would still be free to override __getslice__, but wouldn't have to. -- CARL BANKS -- http://mail.python.org/mailman/listinfo/python-list