This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: __getslice__ still used in built-in types
Type: Stage:
Components: Documentation Versions: Python 2.5
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: georg.brandl Nosy List: bronger, georg.brandl, rhettinger
Priority: normal Keywords:

Created on 2007-04-10 17:06 by bronger, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (3)
msg31748 - (view) Author: Torsten Bronger (bronger) Date: 2007-04-10 17:06
In the Python language reference <http://docs.python.org/ref/sequence-methods.html>, after the sentence

"""Deprecated since release 2.0. Support slice objects as parameters to the __getitem__() method."""

I suggest the following addition:

"""However, built-in types in CPython currently still implement __getslice__.  Therefore, you have to override it in derived classes when implementing slicing."""
msg31749 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2007-04-12 18:34
Sensible suggestion.
msg55204 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2007-08-23 20:35
Fixed in rev. 57343.
History
Date User Action Args
2022-04-11 14:56:23adminsetgithub: 44825
2007-08-23 20:35:14georg.brandlsetstatus: open -> closed
assignee: rhettinger -> georg.brandl
resolution: fixed
messages: + msg55204
nosy: + georg.brandl
2007-04-10 17:06:27brongercreate