summaryrefslogtreecommitdiffstats
path: root/Lib/test/re_tests.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2003-02-24 01:18:35 (GMT)
committerGuido van Rossum <guido@python.org>2003-02-24 01:18:35 (GMT)
commit577fb5a1db508444eed7bd78fbf76c1f64ed643b (patch)
tree8aab690279d808e29afd8740ce06768e51eb08a9 /Lib/test/re_tests.py
parent902a671c7bdaa413670649806776a8dc9000d2a8 (diff)
downloadcpython-577fb5a1db508444eed7bd78fbf76c1f64ed643b.zip
cpython-577fb5a1db508444eed7bd78fbf76c1f64ed643b.tar.gz
cpython-577fb5a1db508444eed7bd78fbf76c1f64ed643b.tar.bz2
Fix from SF patch #633359 by Greg Chapman for SF bug #610299:
The problem is in sre_compile.py: the call to _compile_charset near the end of _compile_info forgets to pass in the flags, so that the info charset is not compiled with re.U. (The info charset is used when searching to find the first character at which a match could start; it is not generated for patterns beginning with a repeat like '\w{1}'.)
Diffstat (limited to 'Lib/test/re_tests.py')
-rwxr-xr-xLib/test/re_tests.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/Lib/test/re_tests.py b/Lib/test/re_tests.py
index 12ad201..7b237ac 100755
--- a/Lib/test/re_tests.py
+++ b/Lib/test/re_tests.py
@@ -666,4 +666,5 @@ else:
# bug 410271: \b broken under locales
(r'\b.\b', 'a', SUCCEED, 'found', 'a'),
(r'(?u)\b.\b', u, SUCCEED, 'found', u),
+ (r'(?u)\w', u, SUCCEED, 'found', u),
])