diff --git a/scintilla/boostregex/BoostRegExSearch.cxx b/scintilla/boostregex/BoostRegExSearch.cxx index afd3853a1..25dda8163 100644 --- a/scintilla/boostregex/BoostRegExSearch.cxx +++ b/scintilla/boostregex/BoostRegExSearch.cxx @@ -416,7 +416,7 @@ void BoostRegexSearch::EncodingDependent::compileRegex { if (_lastCompileFlags != compileFlags || _lastRegexString != regex) { - std::locale l = std::locale(""); + std::locale l = std::locale::global(std::locale("")); _regex = Regex(CharTPtr(regex), static_cast(compileFlags)); std::locale::global(l); _lastRegexString = regex;