[ python-Feature Requests-1528154 ] New sequences for Unicode groups and block ranges needed

SourceForge.net noreply at sourceforge.net
Wed Jul 26 04:06:12 CEST 2006


Feature Requests item #1528154, was opened at 2006-07-25 15:44
Message generated for change (Comment added) made by gmarketer
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=355470&aid=1528154&group_id=5470

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Regular Expressions
Group: None
Status: Open
Resolution: None
Priority: 6
Submitted By: gmarketer (gmarketer)
Assigned to: Nobody/Anonymous (nobody)
>Summary: New sequences for Unicode groups and block ranges needed

Initial Comment:
The special sequences consist of "\" and another
character need to be added to RE sintax to simplify the
finding of several Unicode classes like:
 * All uppercase letters
 * All lowercase letters


----------------------------------------------------------------------

>Comment By: gmarketer (gmarketer)
Date: 2006-07-26 13:06

Message:
Logged In: YES 
user_id=1334865

We need to process several strings in utf-8 and need to use
regular expressions to match pattern, for ex.:
r"[ANY_LANGUAGE_UPPERCASE_LETTER,0-9ANY_LANGUAGE_LOWERCASE_LETTER]+|NOT_ANY_LANGUAGE_CURRENCY"

We don't know how to implement this logic by our hands.

Also, I found this logic implemented in Microsoft dot NET
regular expressions:

\p{name}        Matches any character in the named character
class 'name'. Supported names are Unicode groups and block
ranges. For example Ll, Nd, Z, IsGreek, IsBoxDrawing, and Sc
(currency). 

\P{name}        Matches text not included in the named
character class 'name'. 

We need same logic in regular expressions.


----------------------------------------------------------------------

Comment By: M.-A. Lemburg (lemburg)
Date: 2006-07-25 18:45

Message:
Logged In: YES 
user_id=38388

Could you make your request a little more specific ?

We already have catregories in the re module, so adding a
few more would be possible (patches are welcome !). However,
we do need to know why you need them and whether there are
other RE implementations that already have such special
matching characters, e.g. the Perl RE implementation.


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=355470&aid=1528154&group_id=5470


More information about the Python-bugs-list mailing list