[docs] [issue23532] add example of 'first match wins' to regex "|" documentation?

Matthew Barnett report at bugs.python.org
Fri Feb 27 20:18:42 CET 2015


Matthew Barnett added the comment:

Not quite all. POSIX regexes will always look for the longest match, so the order of the alternatives doesn't matter, i.e. x|xy would give the same result as xy|x.

----------

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


More information about the docs mailing list