Boost logo

Boost Users :

Subject: [Boost-users] Escaping boost.regex literal string fragments
From: Dominique Devienne (ddevienne_at_[hidden])
Date: 2015-10-13 09:20:41


Is there no equivalent to http://doc.qt.io/qt-4.8/qregexp.html#escape in
Boost.Regex, i.e. a way to escape all special characters so they match
"literally"?

There are manual solutions, like
http://stackoverflow.com/questions/1252992/how-to-escape-a-string-for-use-in-boost-regex,
but shouldn't that be part of the API?

Does C++11's std::regex, based on boost::regex, include this API? Thanks,
--DD



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