Poll of the week: How should std.regex handle unknown escape

Dmitry Olshansky dmitry.olsh at gmail.com
Sat Dec 3 07:51:13 PST 2011


On 03.12.2011 16:54, Kagamin wrote:
> Marco Leise Wrote:
>
>> http://www.easypolls.net/poll.html?p=4ed9478e4fb7b0e4886eeea2
>
> Erm... but "\." is a perfectly known escape sequence, so the question should be "How should std.regex handle known escape sequences as in: "[\.]"".

Let's clarify this a bit.
Well \. is more or less common outside of []. The question is more like:
treat every \<something> as plain <something> (ignoring \) inside 
character classes [] if it's not a known escape sequence like \w, \d, 
\uXXXX, \W, \cA -\cZ and so on.


More information about the Digitalmars-d mailing list