HomePhabricator

match: fix re2 compability broken in 2e2699af5649

Authored by marmoute.

Description

match: fix re2 compability broken in 2e2699af5649

When using re2, we call test_match() instead of match() on the
compiled regex object. While match() returns a matcher object or None,
test_match() returns True or False. So since 2e2699af5649 running test
on a machine with a re2 install fails in many places. Instead we make
the code a bit more general and everything goes back to normal.

Details

Committed
marmouteApr 11 2019, 12:34 PM
Parents
rHG5753e5949b51: py3: add b'' prefixes to new doctests in match.py
Branches
Unknown
Tags
Unknown