[issue7940] re.finditer and re.findall should support negative end positions

Zachary Ware report at bugs.python.org
Mon Sep 9 12:45:35 EDT 2019


Zachary Ware <zachary.ware at gmail.com> added the comment:

Ezio requested further opinions, so here's mine.  I don't think the current behavior makes sense; I doubt anyone actually expects a negative index to be squashed to 0, especially for endpos.  I'm not certain that allowing negative indexes is really necessary, but seems nicer than raising an exception which would be the other acceptable option to me.

----------
nosy: +zach.ware

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue7940>
_______________________________________


More information about the Python-bugs-list mailing list