]> granicus.if.org Git - icu/commitdiff
ICU-13450 MSVC has the wrong value for U_CPLUSPLUS_VERSION, check the _MSVC_LANG...
authorJeff Genovy <29107334+jefgen@users.noreply.github.com>
Thu, 22 Feb 2018 21:33:48 +0000 (21:33 +0000)
committerJeff Genovy <29107334+jefgen@users.noreply.github.com>
Thu, 22 Feb 2018 21:33:48 +0000 (21:33 +0000)
X-SVN-Rev: 40977

icu4c/source/common/unicode/platform.h

index 217de4a1801d408289ade0da6c1f409cb06acbea..56f8e5e5b0f2536515f18bcbb6ec0a32564322fe 100644 (file)
     /* Otherwise use the predefined value. */
 #elif !defined(__cplusplus)
 #   define U_CPLUSPLUS_VERSION 0
-#elif __cplusplus >= 201402L
+#elif __cplusplus >= 201402L || (defined(_MSVC_LANG) && _MSVC_LANG >= 201402L)
 #   define U_CPLUSPLUS_VERSION 14
-#elif __cplusplus >= 201103L
+#elif __cplusplus >= 201103L || (defined(_MSVC_LANG) && _MSVC_LANG >= 201103L)
 #   define U_CPLUSPLUS_VERSION 11
 #else
     // C++98 or C++03