diff --git a/src/common/string_util.cpp b/src/common/string_util.cpp index 4cd7cd44a..9b08e5309 100644 --- a/src/common/string_util.cpp +++ b/src/common/string_util.cpp @@ -296,7 +296,7 @@ std::string ReplaceAll(std::string result, const std::string& src, const std::st std::string UTF16ToUTF8(const std::u16string& input) { -#if _MSC_VER >= 1900 && defined(__MINGW64__) +#if _MSC_VER >= 1900 || defined(__MINGW64__) // Workaround for missing char16_t/char32_t instantiations in MSVC2015 std::wstring_convert, __int16> convert; std::basic_string<__int16> tmp_buffer(input.cbegin(), input.cend()); @@ -309,7 +309,7 @@ std::string UTF16ToUTF8(const std::u16string& input) std::u16string UTF8ToUTF16(const std::string& input) { -#if _MSC_VER >= 1900 && defined(__MINGW64__) +#if _MSC_VER >= 1900 || defined(__MINGW64__) // Workaround for missing char16_t/char32_t instantiations in MSVC2015 std::wstring_convert, __int16> convert; auto tmp_buffer = convert.from_bytes(input);