Boost logo

Boost Users :

Subject: Re: [Boost-users] Xpressive Character Literals
From: Etienne Philip Pretorius (icewolfhunter_at_[hidden])
Date: 2009-08-05 15:08:09


Eric Niebler wrote:
> Etienne Philip Pretorius wrote:
>> Hello List,
>>
>> Just a quick question;
>>
>> Xpressive seems not to compile when I use 0x?? instead of 'a' for
>> regular expressions.
>>
>> Eg. sregex characters = +(set=0x20,0x0A,0x0D,0x20,0x33);
>
> Yes, because xpressive expects chars, not ints.
>
>> Is there perhaps a way to accomplish this in Xpressive?
>
> Untested:
>
> sregex characters = +(set='\x20','\x0A','\x0D','\x20','\x33');
>
Thank you... exactly what I was looking for.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net