[issue1647489] zero-length match confuses re.finditer()

Martin Morrison report at bugs.python.org
Fri Apr 19 02:21:29 CEST 2013


Martin Morrison added the comment:

This is still an issue today:

>>> import re
>>> [m.groups() for m in re.finditer(r'(^z*)|(\w+)', 'abc')]
[('', None), (None, 'bc')]

----------
nosy: +isoschiz

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue1647489>
_______________________________________


More information about the Python-bugs-list mailing list