Boost logo

Boost Users :

From: Eoin (eoinoc_at_[hidden])
Date: 2007-05-01 17:02:13


Hello,
I've been playing around with Xpressive and have hit a stumbling block
when working with Unicode. I really am not sure if what I am trying to
do is possible and that I'm just doing something silly wrong. Here is
a very small example-

wstring in = L"A ЏиϊсoδΣ Hello //World";
wsregex comments =
wsregex::compile(L"(//[^\\n]*|/\\*.*?\\*/)");

wstring clear(L"");
wstring out = regex_replace(in, comments, clear);

(Note if the wstring 'in' gets scrambled in email I have attached a
tiny UTF-8 encoded file of what it should contain.) This code compiles
but after executing the wstring 'out' only contains "A ". If there are
no Unicode characters in 'in' then the regex replacement works as
expected.

Kind regards, Eóin.

"A ЏиϊсoδΣ Hello //World"


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