mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
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.
This commit is contained in:
parent
352601ca00
commit
bd48d27944
12 changed files with 58 additions and 34 deletions
|
@ -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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue