diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2008-07-22 17:53:22 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2008-07-22 17:53:22 (GMT) |
commit | 22628c4d6a79e38371e383cc40702bf0935e355e (patch) | |
tree | 05a58350d5a9340d4370e2ab5e6649a664544732 /Lib/test/re_tests.py | |
parent | 943f33912c243b0769023082691475012428da5a (diff) | |
download | cpython-22628c4d6a79e38371e383cc40702bf0935e355e.zip cpython-22628c4d6a79e38371e383cc40702bf0935e355e.tar.gz cpython-22628c4d6a79e38371e383cc40702bf0935e355e.tar.bz2 |
#3231: re.compile fails with some bytes patterns
Diffstat (limited to 'Lib/test/re_tests.py')
-rwxr-xr-x | Lib/test/re_tests.py | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/Lib/test/re_tests.py b/Lib/test/re_tests.py index 25b1229..220301a 100755 --- a/Lib/test/re_tests.py +++ b/Lib/test/re_tests.py @@ -661,12 +661,8 @@ xyzabc ('^([ab]*?)(?<!(a))c', 'abc', SUCCEED, 'g1+"-"+g2', 'ab-None'), ] -try: - u = eval("u'\N{LATIN CAPITAL LETTER A WITH DIAERESIS}'") -except SyntaxError: - pass -else: - tests.extend([ +u = '\N{LATIN CAPITAL LETTER A WITH DIAERESIS}' +tests.extend([ # bug 410271: \b broken under locales (r'\b.\b', 'a', SUCCEED, 'found', 'a'), (r'(?u)\b.\b', u, SUCCEED, 'found', u), |