aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorspreis <spreis@yandex-team.com>2023-02-18 00:26:19 +0300
committerspreis <spreis@yandex-team.com>2023-02-18 00:26:19 +0300
commitfc5c4121ccaeea8b2f707164483394eb1a290fca (patch)
treeac5130666004b3191945cd267d53c818afb6b2f0
parenta0032e21df987d6107944f82a079a56c1ed25d04 (diff)
downloadydb-fc5c4121ccaeea8b2f707164483394eb1a290fca.tar.gz
Fix libcxx build under cl /std:c++14 needed for CUDA
static_assert with one argument is added in `C++17`. The code in PR is used in `C++14` mode through CUDA build. This is needed to build catboost on Windows using cl.exe as CUDA host compiler.
-rw-r--r--contrib/libs/cxxsupp/libcxx/include/vector2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/libs/cxxsupp/libcxx/include/vector b/contrib/libs/cxxsupp/libcxx/include/vector
index 9f5e57f454..9810ac710d 100644
--- a/contrib/libs/cxxsupp/libcxx/include/vector
+++ b/contrib/libs/cxxsupp/libcxx/include/vector
@@ -3294,7 +3294,7 @@ struct _LIBCPP_TEMPLATE_VIS hash<vector<bool, _Allocator> >
size_t __idx = 0;
size_t __n = __vec.size();
constexpr size_t __bits_per_word = sizeof(typename allocator_traits<_Allocator>::size_type) * CHAR_BIT;
- static_assert(sizeof(typename allocator_traits<_Allocator>::size_type) <= sizeof(size_t));
+ static_assert(sizeof(typename allocator_traits<_Allocator>::size_type) <= sizeof(size_t), "size_type constraint violated");
for (;__idx + __bits_per_word <= __n;) {
for (size_t __bit = 0; __bit < __bits_per_word; __bit++, __idx++) {
__h ^= static_cast<size_t>(__vec[__idx]) << __bit;