Added timeout parameter in Python 3. TimeoutError was added in Python 3.3, and as Python 2.7 will soon reach EOL, I'm not bothered about supporting timeouts for Python 2.
2019.3.9
Hg issue 320: Abnormal performance
Forgot about negative lookarounds! Previous change now applies only to positive lookarounds.
2019.3.8
Hg issue 320: Abnormal performance
Included firstset from lookaround, where appropriate.
2019.2.21
Hg issue 316: __version__ no longer accessible via regex.__version__
2019.2.20
Hg issue 314: Import error: "No module named regex._regex_core"