diff options
Diffstat (limited to 'yt_dlp/compat/re.py')
-rw-r--r-- | yt_dlp/compat/re.py | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/yt_dlp/compat/re.py b/yt_dlp/compat/re.py new file mode 100644 index 000000000..e1d3a2645 --- /dev/null +++ b/yt_dlp/compat/re.py @@ -0,0 +1,18 @@ +# flake8: noqa: F405 +from re import * # F403 + +from .compat_utils import passthrough_module + +passthrough_module(__name__, 're') +del passthrough_module + +try: + Pattern # >= 3.7 +except NameError: + Pattern = type(compile('')) + + +try: + Match # >= 3.7 +except NameError: + Match = type(compile('').match('')) |