Bug 5652 – Add \p and \P unicode properties to std.regex

Status
RESOLVED
Resolution
FIXED
Severity
enhancement
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
Other
OS
All
Creation time
2011-02-25T08:25:00Z
Last change time
2012-02-24T11:53:59Z
Assigned to
nobody
Creator
jlquinn
Blocks
6403

Comments

Comment #0 by jlquinn — 2011-02-25T08:25:16Z
It's nice to be able to point to a standard for regexes, but Unicode properties are an invaluable part of writing regexes when dealing with non-ascii text. They are supported by Java, ICU, Perl, and PCRE. If need be, they could be enabled by a flag. I'd definitely recommend providing \p{} and \P{} constructs covering the full unicode standard, but would also highly suggest allowing \pX for single-char properties too.
Comment #1 by dmitry.olsh — 2011-07-30T08:33:25Z
\p and \P properites are part of UTS 18 standard. Superseded by the request for UTS 18 level 1 support: http://d.puremagic.com/issues/show_bug.cgi?id=6261 *** This issue has been marked as a duplicate of issue 6261 ***
Comment #2 by Jesse.K.Phillips+D — 2011-07-30T09:29:47Z
Making this a blocker to 6403. Not sure if it matters much, but 6261 definitely isn't what you meant.
Comment #3 by dmitry.olsh — 2011-07-30T10:51:12Z
Right, and it's definitely better this way.
Comment #4 by dmitry.olsh — 2012-02-24T11:53:59Z
Suppported since 2.057.