mirror of
https://github.com/boostorg/config.git
synced 2026-08-03 20:14:15 +02:00
Merge pull request #539 from ruiji-shi/user/ruishi/clang-cl-wchart-t-guard
Fix Clang Boost wchar_t redefinition
This commit is contained in:
@@ -366,5 +366,15 @@
|
||||
// Macro used to identify the Clang compiler.
|
||||
#define BOOST_CLANG 1
|
||||
|
||||
//
|
||||
// When targeting MSVC compatibility (clang-cl), wchar_t is only a distinct intrinsic
|
||||
// type when _NATIVE_WCHAR_T_DEFINED is defined (i.e. /Zc:wchar_t). Under /Zc:wchar_t-,
|
||||
// wchar_t is an alias for unsigned short, so mirror visualc.hpp here to avoid emitting a
|
||||
// duplicate wchar_t specialization that redefines the unsigned short one.
|
||||
//
|
||||
#if defined(_MSC_VER) && !defined(_NATIVE_WCHAR_T_DEFINED)
|
||||
# define BOOST_NO_INTRINSIC_WCHAR_T
|
||||
#endif
|
||||
|
||||
// BOOST_CLANG_VERSION
|
||||
#include <boost/config/compiler/clang_version.hpp>
|
||||
|
||||
Reference in New Issue
Block a user