[libcxx-commits] [libcxx] a765eea - [libcxx][test] Auto-detect _LIBCPP_HAS_NO_UNICODE for MSVC STL

Casey Carter via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jan 10 13:56:34 PST 2022


Author: Casey Carter
Date: 2022-01-10T13:56:22-08:00
New Revision: a765eea153897eee00eda6a68a9e7d4d84c823b8

URL: https://github.com/llvm/llvm-project/commit/a765eea153897eee00eda6a68a9e7d4d84c823b8
DIFF: https://github.com/llvm/llvm-project/commit/a765eea153897eee00eda6a68a9e7d4d84c823b8.diff

LOG: [libcxx][test] Auto-detect _LIBCPP_HAS_NO_UNICODE for MSVC STL

... by examining `_MSVC_EXECUTION_CHARACTER_SET` in the force-include header.

Differential Revision: https://reviews.llvm.org/D116883

Added: 
    

Modified: 
    libcxx/test/support/msvc_stdlib_force_include.h

Removed: 
    


################################################################################
diff  --git a/libcxx/test/support/msvc_stdlib_force_include.h b/libcxx/test/support/msvc_stdlib_force_include.h
index bd83bee22ce73..b1ce02650a5dc 100644
--- a/libcxx/test/support/msvc_stdlib_force_include.h
+++ b/libcxx/test/support/msvc_stdlib_force_include.h
@@ -104,4 +104,8 @@ const AssertionDialogAvoider assertion_dialog_avoider{};
     __pragma(warning(pop))
 #endif // __clang__
 
+#if defined(_MSVC_EXECUTION_CHARACTER_SET) && _MSVC_EXECUTION_CHARACTER_SET != 65001
+#define _LIBCPP_HAS_NO_UNICODE 1
+#endif
+
 #endif // SUPPORT_MSVC_STDLIB_FORCE_INCLUDE_H


        


More information about the libcxx-commits mailing list