1
這是我的代碼:如何使用boost :: algorithm庫中的replace_regex_copy()?
#include <string>
#include <boost/algorithm/string/regex.hpp>
string f(const string& s) {
using namespace boost::algorithm;
return replace_regex_copy(s, "\\w", "?");
}
這是編譯器說:
no matching function for call to ‘replace_regex_copy(const
std::basic_string<char, std::char_traits<char>,
std::allocator<char> >&, std::string, std::string)
的鏈接庫:http://www.boost.org/doc/libs/1_43_0/doc/html/boost/algorithm/replace_regex_copy.html
誰能請幫助?謝謝!
ps。 Boost庫已經到位,因爲它的其他功能工作正常。
非常感謝您! – yegor256 2010-05-13 09:31:36