[Python-ideas] Where did we go wrong with negative stride?

Charles Hixson charleshixsn at earthlink.net
Mon Oct 28 01:42:06 CET 2013


On 10/27/2013 04:20 PM, Antoine Pitrou wrote:
> On Sun, 27 Oct 2013 16:56:34 -0500
> Tim Peters <tim.peters at gmail.com> wrote:
>> [Guido]
>>> I wouldn't take out negative strides completely, but I might consider
>>> deprecating lower and upper bounds other than None (== missing). So a[::-1]
>>> would still work, and a[None:None:-1] would be a verbose way of spelling the
>>> same,
>> Happy idea.
>>
>>> but a[-1:-6:-1] would be deprecated.
>> Not sure I've _ever_ seen that in real life.
> If it's never seen in real life, then there's probably no urge to
> deprecate it and later replace it with a new thing, IMHO.
>
> Also, I get the feeling it's a bit early to start talking about
> Python 4 (is that supposed to happen at all?).
>
> Regards
>
> Antoine.
>
>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
>
If it's a misfeature and it's not currently being used, then this is the 
perfect time to deprecate it.

-- 
Charles Hixson



More information about the Python-ideas mailing list