diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2016-09-11 12:50:02 +0300 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2016-09-11 12:50:02 +0300 |
commit | bd48d27944453ad83d3ce37b2c867fa0d59a1c15 (patch) | |
tree | f5585b5ce3995541ed6cce7bb4daef97f936be89 /Lib/fnmatch.py | |
parent | 352601ca00376aaf07d4399096f985d3d8ecb96f (diff) | |
download | cpython-git-bd48d27944453ad83d3ce37b2c867fa0d59a1c15.tar.gz |
Issue #22493: Inline flags now should be used only at the start of the
regular expression. Deprecation warning is emitted if uses them in the
middle of the regular expression.
Diffstat (limited to 'Lib/fnmatch.py')
-rw-r--r-- | Lib/fnmatch.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/fnmatch.py b/Lib/fnmatch.py index 07b12295df..fd3b5142e3 100644 --- a/Lib/fnmatch.py +++ b/Lib/fnmatch.py @@ -106,4 +106,4 @@ def translate(pat): res = '%s[%s]' % (res, stuff) else: res = res + re.escape(c) - return res + r'\Z(?ms)' + return r'(?s:%s)\Z' % res |