| /llvm-project-15.0.7/libcxx/test/std/utilities/memory/allocator.traits/ |
| H A D | rebind_traits.pass.cpp | 68 …static_assert((std::is_same<std::allocator_traits<A<char> >::rebind_traits<double>, std::allocator… in main() 69 …static_assert((std::is_same<std::allocator_traits<B<int, char> >::rebind_traits<double>, std::allo… in main() 70 …static_assert((std::is_same<std::allocator_traits<C<char> >::rebind_traits<double>, std::allocator… in main() 71 …static_assert((std::is_same<std::allocator_traits<D<int, char> >::rebind_traits<double>, std::allo… in main() 72 …static_assert((std::is_same<std::allocator_traits<E<char> >::rebind_traits<double>, std::allocator… in main() 74 …static_assert((std::is_same<std::allocator_traits<A<char> >::rebind_traits<double>::other, std::al… in main() 75 …static_assert((std::is_same<std::allocator_traits<B<int, char> >::rebind_traits<double>::other, st… in main() 76 …static_assert((std::is_same<std::allocator_traits<C<char> >::rebind_traits<double>::other, std::al… in main() 77 …static_assert((std::is_same<std::allocator_traits<D<int, char> >::rebind_traits<double>::other, st… in main() 78 …static_assert((std::is_same<std::allocator_traits<E<char> >::rebind_traits<double>::other, std::al… in main()
|
| /llvm-project-15.0.7/libcxx/test/std/utilities/memory/specialized.algorithms/specialized.destroy/ |
| H A D | destroy_at.pass.cpp | 47 Array* ptr = std::allocator_traits<Alloc>::allocate(alloc, 1); in test_arrays() 59 std::allocator_traits<Alloc>::deallocate(alloc, ptr, 1); in test_arrays() 65 Array* ptr = std::allocator_traits<Alloc>::allocate(alloc, 1); in test_arrays() 78 std::allocator_traits<Alloc>::deallocate(alloc, ptr, 1); in test_arrays() 92 std::allocator_traits<Alloc>::construct(alloc, ptr1, &counter); in test() 93 std::allocator_traits<Alloc>::construct(alloc, ptr2, &counter); in test() 103 std::allocator_traits<Alloc>::deallocate(alloc, ptr1, 1); in test() 104 std::allocator_traits<Alloc>::deallocate(alloc, ptr2, 1); in test() 113 std::allocator_traits<Alloc>::construct(alloc, ptr1, &counter); in test() 124 std::allocator_traits<Alloc>::deallocate(alloc, ptr1, 1); in test() [all …]
|
| H A D | destroy.pass.cpp | 38 Array* pool = std::allocator_traits<Alloc>::allocate(alloc, 5); in test_arrays() 43 std::allocator_traits<Alloc>::construct(alloc, std::addressof(arr[i]), &counter); in test_arrays() 52 std::allocator_traits<Alloc>::deallocate(alloc, pool, 5); in test_arrays() 59 Array* pool = std::allocator_traits<Alloc>::allocate(alloc, 5); in test_arrays() 65 … std::allocator_traits<Alloc>::construct(alloc, std::addressof(arr[i][j]), &counter); in test_arrays() 75 std::allocator_traits<Alloc>::deallocate(alloc, pool, 5); in test_arrays() 87 Counted* pool = std::allocator_traits<Alloc>::allocate(alloc, 5); in test() 90 std::allocator_traits<Alloc>::construct(alloc, p, &counter); in test() 97 std::allocator_traits<Alloc>::deallocate(alloc, pool, 5); in test()
|
| H A D | destroy_n.pass.cpp | 38 Array* pool = std::allocator_traits<Alloc>::allocate(alloc, 5); in test_arrays() 43 std::allocator_traits<Alloc>::construct(alloc, std::addressof(arr[i]), &counter); in test_arrays() 53 std::allocator_traits<Alloc>::deallocate(alloc, pool, 5); in test_arrays() 60 Array* pool = std::allocator_traits<Alloc>::allocate(alloc, 5); in test_arrays() 66 … std::allocator_traits<Alloc>::construct(alloc, std::addressof(arr[i][j]), &counter); in test_arrays() 77 std::allocator_traits<Alloc>::deallocate(alloc, pool, 5); in test_arrays() 89 Counted* pool = std::allocator_traits<Alloc>::allocate(alloc, 5); in test() 92 std::allocator_traits<Alloc>::construct(alloc, p, &counter); in test() 100 std::allocator_traits<Alloc>::deallocate(alloc, pool, 5); in test()
|
| /llvm-project-15.0.7/libcxx/test/std/utilities/allocator.adaptor/allocator.adaptor.types/ |
| H A D | is_always_equal.pass.cpp | 29 std::allocator_traits<A1<int>>::is_always_equal, std::false_type>::value in main() 33 std::allocator_traits<min_allocator<int>>::is_always_equal, std::true_type>::value in main() 40 std::allocator_traits<A1<int>>::is_always_equal in main() 47 std::allocator_traits<min_allocator<int>>::is_always_equal in main() 53 ( std::allocator_traits<A1<int>>::is_always_equal::value && in main() 54 std::allocator_traits<A2<int>>::is_always_equal::value) in main() 60 ( std::allocator_traits<A1<int>>::is_always_equal::value && in main() 61 std::allocator_traits<min_allocator<int>>::is_always_equal::value) in main() 68 ( std::allocator_traits<A1<int>>::is_always_equal::value && in main() 69 std::allocator_traits<A2<int>>::is_always_equal::value && in main() [all …]
|
| /llvm-project-15.0.7/libcxx/test/std/utilities/memory/allocator.traits/allocator.traits.types/ |
| H A D | rebind_alloc.pass.cpp | 86 …static_assert((std::is_same<std::allocator_traits<A<char> >::rebind_alloc<double>, ReboundA<double… in main() 87 …static_assert((std::is_same<std::allocator_traits<B<int, char> >::rebind_alloc<double>, ReboundB<d… in main() 88 …static_assert((std::is_same<std::allocator_traits<C<char> >::rebind_alloc<double>, C<double> >::va… in main() 89 …static_assert((std::is_same<std::allocator_traits<D<int, char> >::rebind_alloc<double>, D<double, … in main() 90 …static_assert((std::is_same<std::allocator_traits<E<char> >::rebind_alloc<double>, E<double> >::va… in main() 91 …static_assert((std::is_same<std::allocator_traits<F<char> >::rebind_alloc<double>, F<double> >::va… in main() 92 …static_assert((std::is_same<std::allocator_traits<G<char> >::rebind_alloc<double>, G<double> >::va… in main() 94 …static_assert((std::is_same<std::allocator_traits<A<char> >::rebind_alloc<double>::other, ReboundA… in main() 96 …static_assert((std::is_same<std::allocator_traits<C<char> >::rebind_alloc<double>::other, C<double… in main() 97 …static_assert((std::is_same<std::allocator_traits<D<int, char> >::rebind_alloc<double>::other, D<d… in main() [all …]
|
| H A D | is_always_equal.pass.cpp | 46 …static_assert((std::is_same<std::allocator_traits<A<char> >::is_always_equal, std::true_type>::val… in main() 47 …static_assert((std::is_same<std::allocator_traits<B<char> >::is_always_equal, std::true_type>::val… in main() 48 …static_assert((std::is_same<std::allocator_traits<C<char> >::is_always_equal, std::false_type>::va… in main() 50 …static_assert((std::is_same<std::allocator_traits<A<const char> >::is_always_equal, std::true_type… in main() 51 …static_assert((std::is_same<std::allocator_traits<B<const char> >::is_always_equal, std::true_type… in main() 52 …static_assert((std::is_same<std::allocator_traits<C<const char> >::is_always_equal, std::false_typ… in main()
|
| H A D | void_pointer.pass.cpp | 61 …static_assert((std::is_same<std::allocator_traits<A<char> >::void_pointer, Ptr<void> >::value), ""… in main() 62 static_assert((std::is_same<std::allocator_traits<B<char> >::void_pointer, void*>::value), ""); in main() 63 …static_assert((std::is_same<std::allocator_traits<C<char> >::void_pointer, CPtr<void> >::value), "… in main() 65 static_assert((std::is_same<std::allocator_traits<D<char> >::void_pointer, void*>::value), ""); in main()
|
| H A D | const_void_pointer.pass.cpp | 62 …static_assert((std::is_same<std::allocator_traits<A<char> >::const_void_pointer, Ptr<const void> >… in main() 63 …static_assert((std::is_same<std::allocator_traits<B<char> >::const_void_pointer, const void*>::val… in main() 64 …static_assert((std::is_same<std::allocator_traits<C<char> >::const_void_pointer, CPtr<const void> … in main() 66 …static_assert((std::is_same<std::allocator_traits<D<char> >::const_void_pointer, const void*>::val… in main()
|
| H A D | size_type.pass.cpp | 67 …static_assert((std::is_same<std::allocator_traits<A<char> >::size_type, unsigned short>::value), "… in main() 68 static_assert((std::is_same<std::allocator_traits<B<char> >::size_type, in main() 70 static_assert((std::is_same<std::allocator_traits<C<char> >::size_type, in main() 73 …static_assert((std::is_same<std::allocator_traits<D<char> >::size_type, unsigned short>::value), "… in main()
|
| H A D | const_pointer.pass.cpp | 60 …static_assert((std::is_same<std::allocator_traits<A<char> >::const_pointer, Ptr<const char> >::val… in main() 61 …static_assert((std::is_same<std::allocator_traits<B<char> >::const_pointer, const char*>::value), … in main() 62 …static_assert((std::is_same<std::allocator_traits<C<char> >::const_pointer, CPtr<const char> >::va… in main() 64 …static_assert((std::is_same<std::allocator_traits<D<char> >::const_pointer, const char*>::value), … in main()
|
| H A D | difference_type.pass.cpp | 71 … static_assert((std::is_same<std::allocator_traits<A<char> >::difference_type, short>::value), ""); in main() 72 …static_assert((std::is_same<std::allocator_traits<B<char> >::difference_type, std::ptrdiff_t>::val… in main() 73 …static_assert((std::is_same<std::allocator_traits<C<char> >::difference_type, signed char>::value)… in main() 75 …static_assert((std::is_same<std::allocator_traits<D<char> >::difference_type, std::ptrdiff_t>::val… in main()
|
| H A D | pointer.pass.cpp | 48 static_assert((std::is_same<std::allocator_traits<A<char> >::pointer, Ptr<char> >::value), ""); in main() 49 static_assert((std::is_same<std::allocator_traits<B<char> >::pointer, char*>::value), ""); in main() 51 static_assert((std::is_same<std::allocator_traits<C<char> >::pointer, char*>::value), ""); in main()
|
| H A D | propagate_on_container_swap.pass.cpp | 47 …static_assert((std::is_same<std::allocator_traits<A<char> >::propagate_on_container_swap, std::tru… in main() 48 …static_assert((std::is_same<std::allocator_traits<B<char> >::propagate_on_container_swap, std::fal… in main() 50 …static_assert((std::is_same<std::allocator_traits<C<char> >::propagate_on_container_swap, std::fal… in main()
|
| H A D | propagate_on_container_copy_assignment.pass.cpp | 48 …static_assert((std::is_same<std::allocator_traits<A<char> >::propagate_on_container_copy_assignmen… in main() 49 …static_assert((std::is_same<std::allocator_traits<B<char> >::propagate_on_container_copy_assignmen… in main() 51 …static_assert((std::is_same<std::allocator_traits<C<char> >::propagate_on_container_copy_assignmen… in main()
|
| H A D | propagate_on_container_move_assignment.pass.cpp | 49 …static_assert((std::is_same<std::allocator_traits<A<char> >::propagate_on_container_move_assignmen… in main() 50 …static_assert((std::is_same<std::allocator_traits<B<char> >::propagate_on_container_move_assignmen… in main() 52 …static_assert((std::is_same<std::allocator_traits<C<char> >::propagate_on_container_move_assignmen… in main()
|
| /llvm-project-15.0.7/libcxx/test/std/utilities/memory/allocator.traits/allocator.traits.members/ |
| H A D | destroy.pass.cpp | 88 CountDestructor* pool = std::allocator_traits<Alloc>::allocate(alloc, 1); in test() 90 std::allocator_traits<Alloc>::construct(alloc, pool, &destructors); in test() 93 std::allocator_traits<Alloc>::destroy(alloc, pool); in test() 96 std::allocator_traits<Alloc>::deallocate(alloc, pool, 1); in test() 102 T* pool = std::allocator_traits<Alloc>::allocate(alloc, 1); in test() 103 std::allocator_traits<Alloc>::construct(alloc, pool, nullptr); in test() 104 std::allocator_traits<Alloc>::destroy(alloc, pool); in test() 105 std::allocator_traits<Alloc>::deallocate(alloc, pool, 1); in test() 113 CountDestructor* pool = std::allocator_traits<Alloc>::allocate(alloc, 1); in test() 118 std::allocator_traits<Alloc>::destroy(alloc, pool); in test() [all …]
|
| H A D | max_size.pass.cpp | 49 assert(std::allocator_traits<B<int> >::max_size(b) == 100); in test() 53 assert(std::allocator_traits<B<int> >::max_size(b) == 100); in test() 59 assert(std::allocator_traits<Alloc >::max_size(a) == 100); in test() 64 assert(std::allocator_traits<A<int> >::max_size(a) == in test() 69 assert(std::allocator_traits<A<int> >::max_size(a) == in test() 74 … static_assert(noexcept(std::allocator_traits<std::allocator<int>>::max_size(a)) == true, ""); in test()
|
| H A D | select_on_container_copy_construction.pass.cpp | 54 assert(std::allocator_traits<A<int> >::select_on_container_copy_construction(a).id == 0); in test() 58 assert(std::allocator_traits<A<int> >::select_on_container_copy_construction(a).id == 0); in test() 64 assert(std::allocator_traits<Alloc>::select_on_container_copy_construction(a).id == 0); in test() 69 assert(std::allocator_traits<B<int> >::select_on_container_copy_construction(b).id == 100); in test() 73 assert(std::allocator_traits<B<int> >::select_on_container_copy_construction(b).id == 100); in test()
|
| H A D | construct.pass.cpp | 89 std::allocator_traits<A<A0> >::construct(a, a0, &A0_count); in test() 99 std::allocator_traits<A<A1> >::construct(a, a1, &A1_count, 'c'); in test() 109 std::allocator_traits<A<A2> >::construct(a, a2, &A2_count, 'd', 5); in test() 119 std::allocator_traits<Alloc>::construct(a, vt, nullptr); in test() 132 std::allocator_traits<B<A0> >::construct(b, a0, &A0_count); in test() 145 std::allocator_traits<B<A1> >::construct(b, a1, &A1_count, 'c'); in test() 158 std::allocator_traits<B<A2> >::construct(b, a2, &A2_count, 'd', 5); in test()
|
| H A D | allocate_hint.pass.cpp | 61 assert(std::allocator_traits<A<int> >::allocate(a, 10, nullptr) == &a.storage); in test() 66 assert(std::allocator_traits<Alloc>::allocate(a, 10, nullptr) == &a.storage); in test() 71 assert(std::allocator_traits<B<int> >::allocate(b, 11, nullptr) == &b.storage); in test() 76 assert(std::allocator_traits<Alloc>::allocate(b, 11, nullptr) == &b.storage); in test()
|
| /llvm-project-15.0.7/libcxx/include/__memory/ |
| H A D | allocation_guard.h | 45 using _Pointer = typename allocator_traits<_Alloc>::pointer; 46 using _Size = typename allocator_traits<_Alloc>::size_type; 53 … , __ptr_(allocator_traits<_Alloc>::allocate(__alloc_, __n_)) // initialization order is important in __allocation_guard() 59 allocator_traits<_Alloc>::deallocate(__alloc_, __ptr_, __n_); in ~__allocation_guard()
|
| /llvm-project-15.0.7/clang/test/SemaCXX/ |
| H A D | PR9902.cpp | 17 struct allocator_traits struct 20 template <class T> using rebind_traits = allocator_traits<rebind_alloc<T>>; argument 28 allocator_traits<allocator<char>>::rebind_alloc<int> a; in main()
|
| H A D | PR9908.cpp | 11 struct allocator_traits struct 16 template <class T> using rebind_traits = allocator_traits<rebind_alloc<T>>; argument 32 allocator_traits<A<char> >::rebind_traits<double> a; in main()
|
| /llvm-project-15.0.7/libcxx/include/ |
| H A D | scoped_allocator | 136 static const bool value = allocator_traits<_A0>:: 153 static const bool value = allocator_traits<_A0>:: 170 static const bool value = allocator_traits<_A0>:: 194 allocator_traits<_A0>::is_always_equal::value && 277 allocator_traits<outer_allocator_type>:: 279 allocator_traits<inner_allocator_type>:: 342 allocator_traits<outer_allocator_type>:: 488 {return allocator_traits<outer_allocator_type>:: 492 {return allocator_traits<outer_allocator_type>:: 497 {allocator_traits<outer_allocator_type>:: [all …]
|