[New-bugs-announce] [issue2834] re.IGNORECASE not Unicode-ready

Sven Siegmund report at bugs.python.org
Mon May 12 10:44:10 CEST 2008


New submission from Sven Siegmund <sven.siegmund at gmail.com>:

re cannot ignore case of special latin characters:

Python 3.0a5 (py3k:62932M, May  9 2008, 16:23:11) [MSC v.1500 32 bit 
(Intel)] on win32
>>> 'Á'.lower() == 'á' and 'á'.upper() == 'Á'
True
>>> import re
>>> rx = re.compile('Á', re.IGNORECASE)
>>> rx.match('á') # should match but won't
>>> rx.match('Á') # will match
<_sre.SRE_Match object at 0x014B08A8>
>>> rx = re.compile('á', re.IGNORECASE)
>>> rx.match('Á') # should match but won't
>>> rx.match('á') # will match
<_sre.SRE_Match object at 0x014B08A8>

----------
components: Regular Expressions
messages: 66715
nosy: sven.siegmund
severity: normal
status: open
title: re.IGNORECASE not Unicode-ready
type: behavior
versions: Python 3.0

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue2834>
__________________________________


More information about the New-bugs-announce mailing list