Claudiu.Popa added the comment:

Added the new patch, which addresses Serhiy's comments.
Also, this approach fails when bytes are involved:

>>> import re
>>> re.search(b"a", b"a")
Assertion failed: (PyUnicode_Check(op)), function _PyUnicode_CheckConsistency, 
file Objects/unicodeobject.c, line 309.

Should a check be added for this also?

----------
Added file: http://bugs.python.org/file32143/sre_repr4.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue17087>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to