[Python-Dev] python3k change to slicing (original) (raw)

Neal Becker ndbecker2 at gmail.com
Thu Apr 19 19:33:31 CEST 2007


There is one thing I'd like to see changed in a future python. I always found it surprising, that

x = [1,2,3,4,5] x[1:10] [2, 3, 4, 5]

is not an error. This is perhaps the only case (but a fundamental one!) where an error is silently ignored.

I really can't think of a good justification for it. If I really meant x[1:] I would have said so.



More information about the Python-Dev mailing list