diff options
author | mikhnenko <mikhnenko@yandex-team.com> | 2024-09-10 09:59:14 +0300 |
---|---|---|
committer | mikhnenko <mikhnenko@yandex-team.com> | 2024-09-10 10:09:43 +0300 |
commit | e64a238636c4c49722fee79e2e75e52a4cb1a882 (patch) | |
tree | c345fcab472258bfceefa9b4a560b4fab57686fd /contrib/libs/cxxsupp/libcxx | |
parent | 3129b5d3576b7d2eacd46bb11e49d0b33f2f433b (diff) | |
download | ydb-e64a238636c4c49722fee79e2e75e52a4cb1a882.tar.gz |
Fix clangd OOM by importing commit from future
import `c37734d40904ebe9c7cc345aab6be3649b0a903c` from upstream
33a38085aa39d27a75d5a86497970a623adc7460
Diffstat (limited to 'contrib/libs/cxxsupp/libcxx')
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/__numeric/midpoint.h | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/contrib/libs/cxxsupp/libcxx/include/__numeric/midpoint.h b/contrib/libs/cxxsupp/libcxx/include/__numeric/midpoint.h index 5325f5e6b3..e7db992a21 100644 --- a/contrib/libs/cxxsupp/libcxx/include/__numeric/midpoint.h +++ b/contrib/libs/cxxsupp/libcxx/include/__numeric/midpoint.h @@ -52,13 +52,8 @@ _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK } -template <class _TPtr> -_LIBCPP_INLINE_VISIBILITY constexpr -enable_if_t<is_pointer_v<_TPtr> - && is_object_v<remove_pointer_t<_TPtr>> - && ! is_void_v<remove_pointer_t<_TPtr>> - && (sizeof(remove_pointer_t<_TPtr>) > 0), _TPtr> -midpoint(_TPtr __a, _TPtr __b) noexcept +template <class _Tp, enable_if_t<is_object_v<_Tp> && !is_void_v<_Tp> && (sizeof(_Tp) > 0), int> = 0> +_LIBCPP_HIDE_FROM_ABI constexpr _Tp* midpoint(_Tp* __a, _Tp* __b) noexcept { return __a + _VSTD::midpoint(ptrdiff_t(0), __b - __a); } |