Boost logo

Boost Users :

Subject: Re: [Boost-users] Boost Regex: Use boost::uint32_t as character type.
From: Etienne Philip Pretorius (icewolfhunter_at_[hidden])
Date: 2009-07-14 05:35:02


John Maddock wrote:
>> I just like to know, if you can use a std::vector<boost::uint32_t> as a
>> source to match regular expressions against it.
>
> Yes but... not right out of the box, you would need to provide a traits
> class so that regex_traits<uint32_t> knows how to interpret unint32_t's
> as characters.
>
> What precisely did you want to do?
>

Convert UTF-8/UTF-16 to unint32_t then use Regular Expressions as a
means to parse xml.

http://www.cs.sfu.ca/~cameron/REX.html (bit outdated)

> HTH, John.
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users


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