Boost logo

Boost Users :

Subject: Re: [Boost-users] spurious string
From: OvermindDL1 (overminddl1_at_[hidden])
Date: 2009-10-01 01:32:12


On Wed, Sep 30, 2009 at 10:54 PM, Surya Kiran Gullapalli
<suryakiran.gullapalli_at_[hidden]> wrote:
> Hello all,
>
> I'm reading an html file and parsing data from it. I've encountered a
> spurious string (researcher’s). Notepad++ shows that string as
> researcher's .
>
> I'm reading the file using std::fstream class. Is there any way i can read
> the string and get the spurious characters replaced using boost string/regex
> algorithms ?

It is not spurious, it is probably a UTF-8 file or something. Can you
attach it, if so then we can confirm that.

But yes, you can do such a replacement with Boost.Regex, although I
would recommend doing it with Boost.Xpressive instead (it even has an
example doing such a replace in the docs, and if you use the static
version it will run faster).


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