[New-bugs-announce] [issue38915] 'r[/]*', str, re.MULTILINE | re.DOTALL Won't match // in a string in Python3.6.8

Yan report at bugs.python.org
Tue Nov 26 06:40:34 EST 2019


New submission from Yan <yanioaioan at gmail.com>:

str="//"
matches = re.finditer('r[/]*', str, re.MULTILINE | re.DOTALL)
for match in matches:
    print(match.group(0))

The above will match double forward slash in Python2.7.15  but NOT in Python3.6.8.

----------
components: Library (Lib)
messages: 357492
nosy: yanioaioan
priority: normal
severity: normal
status: open
title: 'r[/]*', str, re.MULTILINE | re.DOTALL Won't match // in a string in Python3.6.8
type: behavior
versions: Python 3.6

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue38915>
_______________________________________


More information about the New-bugs-announce mailing list