[issue2041] __getslice__ still called

2008-02-07 Thread Stefan Seefeld
Stefan Seefeld added the comment: Mark, thanks for the quick follow-up. OK, i now understand the situation better. The documentation I had read originally didn't talk about special-casing built-in objects. (And since I want to extend a tuple, I do have to override __getslice__ since I want

[issue2041] __getslice__ still called

2008-02-07 Thread Mark Dickinson
Mark Dickinson added the comment: I think the docs do a good job of explaining this; in particular, they say, in http://docs.python.org/dev/reference/datamodel.html#special-method- names: However, built-in types in CPython currently still implement __getslice__(). and explain that

[issue2041] __getslice__ still called

2008-02-07 Thread Stefan Seefeld
New submission from Stefan Seefeld: The python documentation states that since python 2.0 __getslice__ is obsoleted by __getitem__. However, testing with python 2.3 as well as 2.5, I find the following surprising behavior: class Tuple(tuple): def __getitem__(self, i): print '__getitem__', i

[issue2041] __getslice__ still called

2008-02-07 Thread Mark Dickinson
Mark Dickinson added the comment: Well, documentation patches are always welcome, I believe :) If you can point to a particular place in the documentation and suggest alternative (or extra) wording that might help, post it here and I'll deal with it. -- resolution: - invalid status: