diff options
author | David Majnemer <david.majnemer@gmail.com> | 2015-03-18 07:53:18 +0000 |
---|---|---|
committer | David Majnemer <david.majnemer@gmail.com> | 2015-03-18 07:53:18 +0000 |
commit | aaf2b84f99bdf5532dc4f0d1121fe96518c904ea (patch) | |
tree | 13f599baf8167beae1b3fb1f2ac42bb8e80b6d6e /clang/test/SemaCXX/MicrosoftCompatibility.cpp | |
parent | 4b1ba6f09f9311c31cf01c1079ed956633567009 (diff) | |
download | bcm5719-llvm-aaf2b84f99bdf5532dc4f0d1121fe96518c904ea.tar.gz bcm5719-llvm-aaf2b84f99bdf5532dc4f0d1121fe96518c904ea.zip |
MS ABI: Define _HAS_CHAR16_T_LANGUAGE_SUPPORT when appropriate
If we are in MSVC 2015 compatibility mode and C++11 language conformance
is enabled, define _HAS_CHAR16_T_LANGUAGE_SUPPORT to 1.
llvm-svn: 232615
Diffstat (limited to 'clang/test/SemaCXX/MicrosoftCompatibility.cpp')
-rw-r--r-- | clang/test/SemaCXX/MicrosoftCompatibility.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/clang/test/SemaCXX/MicrosoftCompatibility.cpp b/clang/test/SemaCXX/MicrosoftCompatibility.cpp index 480c7cbdcac..1536007a647 100644 --- a/clang/test/SemaCXX/MicrosoftCompatibility.cpp +++ b/clang/test/SemaCXX/MicrosoftCompatibility.cpp @@ -1,13 +1,17 @@ // RUN: %clang_cc1 %s -triple i686-pc-win32 -fsyntax-only -std=c++11 -Wmicrosoft -verify -fms-compatibility -fexceptions -fcxx-exceptions -fms-compatibility-version=19.00 // RUN: %clang_cc1 %s -triple i686-pc-win32 -fsyntax-only -std=c++11 -Wmicrosoft -verify -fms-compatibility -fexceptions -fcxx-exceptions -fms-compatibility-version=18.00 -#if _MSC_VER >= 1900 +#if defined(_HAS_CHAR16_T_LANGUAGE_SUPPORT) && _HAS_CHAR16_T_LANGUAGE_SUPPORT char16_t x; char32_t y; -_Atomic(int) z; #else typedef unsigned short char16_t; typedef unsigned int char32_t; +#endif + +#if _MSC_VER >= 1900 +_Atomic(int) z; +#else struct _Atomic {}; #endif |