From 895dbcbe7db4f465b64ab9a40e3fbbd33be2aabd Mon Sep 17 00:00:00 2001 From: qPCR4vir Date: Fri, 22 May 2015 23:26:42 +0200 Subject: [PATCH] FIX: compiling with VC2015 RC --- include/nana/config.hpp | 14 +++++++++++++- source/gui/widgets/combox.cpp | 2 ++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/include/nana/config.hpp b/include/nana/config.hpp index 77b9005c..fecf633f 100644 --- a/include/nana/config.hpp +++ b/include/nana/config.hpp @@ -13,6 +13,18 @@ #ifndef NANA_CONFIG_HPP #define NANA_CONFIG_HPP + +#if defined(_MSC_VER) +#if (_MSC_VER == 1900) + // google: break any code that tries to use codecvt or codecvt. + // google: It appears the C++ libs haven't been compiled with native char16_t/char32_t support. + // google: Those definitions are for codecvt::id, codecvt::id and codecvt::id respectively. + // However, the codecvt::id and codecvt::id definitions aren't there, and indeed, if you look at locale0.cpp in the CRT source code you'll see they're not defined at all. + // google: That's a known issue, tracked by an active bug (DevDiv#1060849). We were able to update the STL's headers in response to char16_t/char32_t, but we still need to update the separately compiled sources. +#define STD_CODECVT_NOT_SUPPORTED +#endif // _MSC_VER == 1900 +#endif // _MSVC + //Select platform automatically #if defined(_WIN32) || defined(__WIN32__) || defined(WIN32) //Windows: @@ -35,7 +47,7 @@ #define PLATFORM_SPEC_HPP #define STD_CODECVT_NOT_SUPPORTED #else -# static_assert(false, "Only Windows and Unix are support now"); +# static_assert(false, "Only Windows and Unix are supported now"); #endif #if defined(NANA_MINGW) || defined(NANA_LINUX) diff --git a/source/gui/widgets/combox.cpp b/source/gui/widgets/combox.cpp index b1d401f5..64208c54 100644 --- a/source/gui/widgets/combox.cpp +++ b/source/gui/widgets/combox.cpp @@ -18,6 +18,8 @@ #include #include +#include + namespace nana { arg_combox::arg_combox(combox& wdg): widget(wdg)