【发布时间】:2012-04-23 05:50:20
【问题描述】:
在 boost 1.48.0 中,我在正则表达式代码 (boost/regex/v4/w32_regex_traits.hpp) 中找到了这个:
w32_regex_traits()
: m_pimpl(re_detail::create_w32_regex_traits<charT>(::boost::re_detail::w32_get_default_locale()))
{ }
//...//
BOOST_REGEX_DECL lcid_type BOOST_REGEX_CALL w32_get_default_locale()
{
return ::GetUserDefaultLCID();
}
我需要覆盖这个 w32_get_default_locale() 因为我总是希望设置美国语言环境。在不修改源代码的情况下如何做到这一点?
【问题讨论】:
标签: c++ regex boost locale boost-regex