Issue 1713999: Multiple re.compile flags cause error (original) (raw)

Issue1713999

Created on 2007-05-07 02:05 by saulspatz, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (3)
msg31962 - (view) Author: Saul Spatz (saulspatz) Date: 2007-05-07 02:05
The documentation for re.compile() shows that multiple flags are allowed, but re.compile(r'.*', re.VERBOSE, re.DOTALL) results in an error message that only two arguments are allowed and three were given. I'm using python 2.5 with Windows XP Home edition.
msg31963 - (view) Author: Gabriel Genellina (ggenellina) Date: 2007-05-07 05:10
Multiple flags must be ORed together: re.compile(r'.*', re.VERBOSE | re.DOTALL) From the re module documentation at http://docs.python.org/lib/node46.html: "Values can be any of the following variables, combined using bitwise OR (the operator)."
msg31964 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2007-05-07 08:35
Closing as invalid.
History
Date User Action Args
2022-04-11 14:56:24 admin set github: 44938
2007-05-07 02:05:29 saulspatz create