Boost logo

Boost Users :

From: pps (i-love-spam_at_[hidden])
Date: 2005-03-05 15:07:29


Hello,
I have problem creating case less, global match and multi line regexes
in boost and I'd like to ask for a few examples of equivalent
(Javascript's RegEx <-> boost::regex) regex test

js:
string.match( /^abc/ )
string.match( /^abc/i)
string.match( /^abc/g)
string.match( /^abc/m)

c++
regex_match(string, regex("^abc"), match_default)
regex_match(string, regex("^abc"), match_default | icase) // <- is it
correct?
regex_match(string, regex("^abc"), ?? ) //global match?
regex_match(string, regex("^abc"), ?? ) //multi line?

also I'd like to ask what are the proper namespaces/typedefs/enums I
have to use for match flags (for example, there's
boost::regex_constants::icase and boost::regex::icase etc...)

Thank you


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