[pypy-commit] pypy py3k: py3k-ify, __getslice__ vs __getitem__

antocuni noreply at buildbot.pypy.org
Thu Apr 19 15:34:00 CEST 2012


Author: Antonio Cuni <anto.cuni at gmail.com>
Branch: py3k
Changeset: r54538:ab9676ffcac3
Date: 2012-04-19 15:33 +0200
http://bitbucket.org/pypy/pypy/changeset/ab9676ffcac3/

Log:	py3k-ify, __getslice__ vs __getitem__

diff --git a/pypy/objspace/std/test/test_index.py b/pypy/objspace/std/test/test_index.py
--- a/pypy/objspace/std/test/test_index.py
+++ b/pypy/objspace/std/test/test_index.py
@@ -285,7 +285,7 @@
             def __getitem__(self, slice):
                 return slice
 
-        assert X()[-2:1] == (-2, 1)
+        assert X()[-2:1] == slice(-2, 1)
 
     def test_sequence_repeat(self):
         raises(OverflowError, lambda: "a" * self.pos)


More information about the pypy-commit mailing list