Boost logo

Boost Users :

Subject: [Boost-users] xpressive: regex to catch HTML generic tag with back reference to tag name
From: Mia (mia_at_[hidden])
Date: 2015-09-10 18:20:50


Hello,I am quite new to Boost Xpressive, I am using C++ on Visual Studio 2013
and Boost 1_58_0I need to clean up some text from all HTML tagsI an trying
to use this regex:wsregex html_any_tag_regex =
wsregex::compile("^([^<]*)?<([A-Za-z][A-Za-z0-9]*)[^>]*>(.+)<\\/(\\2)>(.*)?$");this
regex causes compilation error: error C2664: 'int
boost::mpl::assertion_failed(boost::mpl::assert::type)' : cannot convert
argument 1 from 'boost::mpl::failed
************boost::is_same<wchar_t,char>::* ***********' to
'boost::mpl::assert::type'I tested my regex
here:http://www.myezapp.com/apps/dev/regexp/show.wsand it is parsed exactly
to my needs.What am I doing wrong?Thank youMia

--
View this message in context: http://boost.2283326.n4.nabble.com/xpressive-regex-to-catch-HTML-generic-tag-with-back-reference-to-tag-name-tp4679958.html
Sent from the Boost - Users mailing list archive at Nabble.com.


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