diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2023-12-25 17:35:41 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2024-04-06 20:13:06 +0000 |
commit | cb14a3fe5122c879eae1fb480ed7ce82a699ddb6 (patch) | |
tree | b983a613c35ece61d561b5a9ef9cd66419f6c7fb /contrib/llvm-project/libcxx/include/__memory/uses_allocator.h | |
parent | 3d68ee6cbdb244de9fab1df8a2525d2fa592571e (diff) | |
parent | 99aabd70801bd4bc72c4942747f6d62c675112f5 (diff) | |
download | src-cb14a3fe5122c879eae1fb480ed7ce82a699ddb6.tar.gz src-cb14a3fe5122c879eae1fb480ed7ce82a699ddb6.zip |
Merge llvm-project main llvmorg-18-init-15692-g007ed0dccd6a
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvm-project main llvmorg-18-init-15692-g007ed0dccd6a.
PR: 276104
MFC after: 1 month
Diffstat (limited to 'contrib/llvm-project/libcxx/include/__memory/uses_allocator.h')
-rw-r--r-- | contrib/llvm-project/libcxx/include/__memory/uses_allocator.h | 27 |
1 files changed, 10 insertions, 17 deletions
diff --git a/contrib/llvm-project/libcxx/include/__memory/uses_allocator.h b/contrib/llvm-project/libcxx/include/__memory/uses_allocator.h index f82ac1796383..84310c3fa567 100644 --- a/contrib/llvm-project/libcxx/include/__memory/uses_allocator.h +++ b/contrib/llvm-project/libcxx/include/__memory/uses_allocator.h @@ -21,33 +21,26 @@ _LIBCPP_BEGIN_NAMESPACE_STD template <class _Tp> -struct __has_allocator_type -{ +struct __has_allocator_type { private: - template <class _Up> static false_type __test(...); - template <class _Up> static true_type __test(typename _Up::allocator_type* = 0); + template <class _Up> + static false_type __test(...); + template <class _Up> + static true_type __test(typename _Up::allocator_type* = 0); + public: - static const bool value = decltype(__test<_Tp>(0))::value; + static const bool value = decltype(__test<_Tp>(0))::value; }; template <class _Tp, class _Alloc, bool = __has_allocator_type<_Tp>::value> -struct __uses_allocator - : public integral_constant<bool, - is_convertible<_Alloc, typename _Tp::allocator_type>::value> -{ +struct __uses_allocator : public integral_constant<bool, is_convertible<_Alloc, typename _Tp::allocator_type>::value> { }; template <class _Tp, class _Alloc> -struct __uses_allocator<_Tp, _Alloc, false> - : public false_type -{ -}; +struct __uses_allocator<_Tp, _Alloc, false> : public false_type {}; template <class _Tp, class _Alloc> -struct _LIBCPP_TEMPLATE_VIS uses_allocator - : public __uses_allocator<_Tp, _Alloc> -{ -}; +struct _LIBCPP_TEMPLATE_VIS uses_allocator : public __uses_allocator<_Tp, _Alloc> {}; #if _LIBCPP_STD_VER >= 17 template <class _Tp, class _Alloc> |