Hi John,
Darren Garvey wrote:
>> Is the example above supposed to work?
Nope: different iterator types: cmatch supports const char* iterators, but
basic_string::const_iterator isn't necessarily that type (though sometimes
it is, depending on the platform/compiler). You should be using
boost::smatch as the match_results type when searching a std::string.
HTH, John.