| /llvm-project-15.0.7/libcxx/test/std/strings/basic.string/string.cons/ |
| H A D | implicit_deduction_guides.pass.cpp | 50 using TestSizeT = test_allocator<char>::size_type; in test() 72 std::basic_string s(6ull, 'a', test_allocator<char>{}); in test() 91 test_allocator<wchar_t>>; in test() 107 test_allocator<wchar_t>>; in test() 123 test_allocator<wchar_t>>; in test() 139 test_allocator<wchar_t>>; in test() 165 test_allocator<wchar_t>>; in test() 190 test_allocator<wchar_t>>; in test() 250 std::basic_string w(win, test_allocator<wchar_t>{}); in test() 326 std::basic_string s(sv, test_allocator<char>{}); in test() [all …]
|
| /llvm-project-15.0.7/libcxx/test/std/containers/sequences/vector.bool/ |
| H A D | move_alloc.pass.cpp | 24 std::vector<bool, test_allocator<bool> > l(test_allocator<bool>(5)); in tests() 25 std::vector<bool, test_allocator<bool> > lo(test_allocator<bool>(5)); in tests() 31 std::vector<bool, test_allocator<bool> > l2(std::move(l), test_allocator<bool>(6)); in tests() 34 assert(l2.get_allocator() == test_allocator<bool>(6)); in tests() 37 std::vector<bool, test_allocator<bool> > l(test_allocator<bool>(5)); in tests() 38 std::vector<bool, test_allocator<bool> > lo(test_allocator<bool>(5)); in tests() 44 std::vector<bool, test_allocator<bool> > l2(std::move(l), test_allocator<bool>(5)); in tests() 47 assert(l2.get_allocator() == test_allocator<bool>(5)); in tests()
|
| H A D | assign_move.pass.cpp | 24 std::vector<bool, test_allocator<bool> > l(test_allocator<bool>(5)); in tests() 25 std::vector<bool, test_allocator<bool> > lo(test_allocator<bool>(5)); in tests() 31 std::vector<bool, test_allocator<bool> > l2(test_allocator<bool>(5)); in tests() 38 std::vector<bool, test_allocator<bool> > l(test_allocator<bool>(5)); in tests() 39 std::vector<bool, test_allocator<bool> > lo(test_allocator<bool>(5)); in tests() 45 std::vector<bool, test_allocator<bool> > l2(test_allocator<bool>(6)); in tests() 49 assert(l2.get_allocator() == test_allocator<bool>(6)); in tests()
|
| /llvm-project-15.0.7/libcxx/test/std/containers/sequences/list/list.cons/ |
| H A D | move_alloc.pass.cpp | 25 std::list<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in main() 26 std::list<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in main() 32 … std::list<MoveOnly, test_allocator<MoveOnly> > l2(std::move(l), test_allocator<MoveOnly>(6)); in main() 35 assert(l2.get_allocator() == test_allocator<MoveOnly>(6)); in main() 38 std::list<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in main() 39 std::list<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in main() 45 … std::list<MoveOnly, test_allocator<MoveOnly> > l2(std::move(l), test_allocator<MoveOnly>(5)); in main() 48 assert(l2.get_allocator() == test_allocator<MoveOnly>(5)); in main()
|
| H A D | assign_move.pass.cpp | 25 std::list<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in main() 26 std::list<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in main() 32 std::list<MoveOnly, test_allocator<MoveOnly> > l2(test_allocator<MoveOnly>(5)); in main() 33 std::list<MoveOnly, test_allocator<MoveOnly> >::iterator it = l.begin(); in main() 41 std::list<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in main() 42 std::list<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in main() 48 std::list<MoveOnly, test_allocator<MoveOnly> > l2(test_allocator<MoveOnly>(6)); in main() 52 assert(l2.get_allocator() == test_allocator<MoveOnly>(6)); in main()
|
| /llvm-project-15.0.7/libcxx/test/std/containers/container.adaptors/priority.queue/priqueue.cons.alloc/ |
| H A D | ctor_copy_alloc.pass.cpp | 32 : public std::priority_queue<T, std::vector<T, test_allocator<T> > > 34 typedef std::priority_queue<T, std::vector<T, test_allocator<T> > > base; 38 explicit test(const test_allocator<int>& a) : base(a) {} in test() 39 test(const value_compare& compare, const test_allocator<int>& a) in test() 42 const test_allocator<int>& a) : base(compare, container, a) {} in test() 43 test(const test& q, const test_allocator<int>& a) : base(q, a) {} in test() 44 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 52 make<std::vector<int, test_allocator<int> > >(5), in main() 53 test_allocator<int>(2)); in main() 54 test<int> q(qo, test_allocator<int>(6)); in main() [all …]
|
| H A D | ctor_move_alloc.pass.cpp | 37 : public std::priority_queue<T, std::vector<T, test_allocator<T> > > 39 typedef std::priority_queue<T, std::vector<T, test_allocator<T> > > base; 43 explicit test(const test_allocator<int>& a) : base(a) {} in test() 44 test(const value_compare& compare, const test_allocator<int>& a) in test() 47 const test_allocator<int>& a) : base(compare, container, a) {} in test() 50 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 51 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 60 make<std::vector<MoveOnly, test_allocator<MoveOnly> > >(5), in main() 61 test_allocator<MoveOnly>(2)); in main() 62 test<MoveOnly> q(std::move(qo), test_allocator<MoveOnly>(6)); in main() [all …]
|
| H A D | ctor_comp_cont_alloc.pass.cpp | 33 : public std::priority_queue<T, std::vector<T, test_allocator<T> > > 35 typedef std::priority_queue<T, std::vector<T, test_allocator<T> > > base; 39 explicit test(const test_allocator<int>& a) : base(a) {} in test() 40 test(const value_compare& compare, const test_allocator<int>& a) in test() 43 const test_allocator<int>& a) : base(compare, container, a) {} in test() 46 const test_allocator<int>& a) : base(compare, std::move(container), a) {} in test() 47 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 49 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 56 typedef std::vector<int, test_allocator<int> > C; in main() 58 test<int> q(std::less<int>(), v, test_allocator<int>(3)); in main() [all …]
|
| H A D | ctor_comp_rcont_alloc.pass.cpp | 33 : public std::priority_queue<T, std::vector<T, test_allocator<T> > > 35 typedef std::priority_queue<T, std::vector<T, test_allocator<T> > > base; 39 explicit test(const test_allocator<int>& a) : base(a) {} in test() 40 test(const value_compare& compare, const test_allocator<int>& a) in test() 43 const test_allocator<int>& a) : base(compare, container, a) {} in test() 46 const test_allocator<int>& a) : base(compare, std::move(container), a) {} in test() 47 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 49 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 56 typedef std::vector<int, test_allocator<int> > C; in main() 57 test<int> q(std::less<int>(), make<C>(5), test_allocator<int>(3)); in main() [all …]
|
| H A D | ctor_comp_alloc.pass.cpp | 22 : public std::priority_queue<T, std::vector<T, test_allocator<T> > > 24 typedef std::priority_queue<T, std::vector<T, test_allocator<T> > > base; 28 explicit test(const test_allocator<int>& a) : base(a) {} in test() 29 test(const value_compare& compare, const test_allocator<int>& a) in test() 32 const test_allocator<int>& a) : base(compare, container, a) {} in test() 35 const test_allocator<int>& a) : base(compare, std::move(container), a) {} in test() 36 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 38 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 45 test<int> q(std::less<int>(), test_allocator<int>(3)); in main() 46 assert(q.c.get_allocator() == test_allocator<int>(3)); in main()
|
| H A D | ctor_alloc.pass.cpp | 22 : public std::priority_queue<T, std::vector<T, test_allocator<T> > > 24 typedef std::priority_queue<T, std::vector<T, test_allocator<T> > > base; 28 explicit test(const test_allocator<int>& a) : base(a) {} in test() 29 test(const value_compare& comp, const test_allocator<int>& a) in test() 32 const test_allocator<int>& a) : base(comp, container, a) {} in test() 35 const test_allocator<int>& a) : base(comp, std::move(container), a) {} in test() 36 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 38 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 45 test<int> q((test_allocator<int>(3))); in main() 46 assert(q.c.get_allocator() == test_allocator<int>(3)); in main()
|
| /llvm-project-15.0.7/libcxx/test/std/containers/container.requirements/container.requirements.general/ |
| H A D | allocator_move.pass.cpp | 67 test<std::vector<int, test_allocator<int> > >(); in main() 68 test<std::vector<bool, test_allocator<bool> > >(); in main() 69 test<std::list<int, test_allocator<int> > >(); in main() 70 test<std::forward_list<int, test_allocator<int> > >(); in main() 78 test<std::deque<int, test_allocator<int> > >(stored_allocators); in main() 81 test<std::set<int, std::less<int>, test_allocator<int> > >(); in main() 82 test<std::multiset<int, std::less<int>, test_allocator<int> > >(); in main() 85 test<std::map<int, int, std::less<int>, test_allocator<KV> > >(); in main() 86 test<std::multimap<int, int, std::less<int>, test_allocator<KV> > >(); in main() 96 test_allocator<int> > >(stored_allocators); in main() [all …]
|
| /llvm-project-15.0.7/libcxx/test/std/containers/container.adaptors/queue/queue.cons.alloc/ |
| H A D | ctor_alloc.pass.cpp | 21 : private std::queue<int, std::deque<int, test_allocator<int> > > 23 typedef std::queue<int, std::deque<int, test_allocator<int> > > base; 25 explicit test(const test_allocator<int>& a) : base(a) {} in test() 26 test(const container_type& container, const test_allocator<int>& a) : base(container, a) {} in test() 28 … test(container_type&& container, const test_allocator<int>& a) : base(std::move(container), a) {} in test() 29 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 31 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 36 test q(test_allocator<int>(3)); in main() 37 assert(q.get_allocator() == test_allocator<int>(3)); in main()
|
| H A D | ctor_container_alloc.pass.cpp | 31 typedef std::deque<int, test_allocator<int> > C; 38 explicit test(const test_allocator<int>& a) : base(a) {} in test() 39 test(const container_type& container, const test_allocator<int>& a) : base(container, a) {} in test() 41 … test(container_type&& container, const test_allocator<int>& a) : base(std::move(container), a) {} in test() 42 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 44 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 50 test q(d, test_allocator<int>(4)); in main() 51 assert(q.get_allocator() == test_allocator<int>(4)); in main()
|
| /llvm-project-15.0.7/libcxx/test/std/containers/container.adaptors/stack/stack.cons.alloc/ |
| H A D | ctor_alloc.pass.cpp | 21 : private std::stack<int, std::deque<int, test_allocator<int> > > 23 typedef std::stack<int, std::deque<int, test_allocator<int> > > base; 25 explicit test(const test_allocator<int>& a) : base(a) {} in test() 26 test(const container_type& cont, const test_allocator<int>& a) : base(cont, a) {} in test() 28 test(container_type&& cont, const test_allocator<int>& a) : base(std::move(cont), a) {} in test() 29 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 31 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 36 test q(test_allocator<int>(3)); in main() 37 assert(q.get_allocator() == test_allocator<int>(3)); in main()
|
| H A D | ctor_container_alloc.pass.cpp | 31 typedef std::deque<int, test_allocator<int> > C; 38 explicit test(const test_allocator<int>& a) : base(a) {} in test() 39 test(const container_type& cont, const test_allocator<int>& a) : base(cont, a) {} in test() 41 test(container_type&& cont, const test_allocator<int>& a) : base(std::move(cont), a) {} in test() 42 test(test&& q, const test_allocator<int>& a) : base(std::move(q), a) {} in test() 44 test_allocator<int> get_allocator() {return c.get_allocator();} in get_allocator() 50 test q(d, test_allocator<int>(4)); in main() 51 assert(q.get_allocator() == test_allocator<int>(4)); in main()
|
| /llvm-project-15.0.7/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.cnstr/ |
| H A D | alloc_convert_non_const_copy.pass.cpp | 41 const test_allocator<int>&, std::tuple<MutableCopy>&>); 48 const test_allocator<int>&, std::tuple<MutableCopy>&>); 59 std::tuple<ConvertibleFrom<MutableCopy>> t2 = {std::allocator_arg, test_allocator<int>{}, t1}; in test() 68 …std::tuple<ConvertibleFrom<MutableCopy>, int> t2 = {std::allocator_arg_t{}, test_allocator<int>{},… in test() 78 …std::tuple<ExplicitConstructibleFrom<MutableCopy>> t2{std::allocator_arg_t{}, test_allocator<int>{… in test() 96 …rt(!std::is_constructible_v<std::tuple<int, int>, std::allocator_arg_t, const test_allocator<int>&, in test() 103 const test_allocator<int>&, std::tuple<int, int>&>); in test() 108 … std::tuple<ConvertibleFrom<TracedCopyMove>> t2{std::allocator_arg_t{}, test_allocator<int>{}, t1}; in test() 116 std::tuple<TracedCopyMove> t2{std::allocator_arg_t{}, test_allocator<int>{}, t1}; in test() 124 … std::tuple<TracedCopyMove, TracedCopyMove> t2{std::allocator_arg_t{}, test_allocator<int>{}, t1}; in test() [all …]
|
| H A D | alloc_convert_const_move.pass.cpp | 41 const test_allocator<int>&, const std::tuple<ConstMove>&&>); 45 const test_allocator<int>&, const std::tuple<ConstMove, ConstMove>&&>); 48 const test_allocator<int>&, const std::tuple<ConstMove>&&>); 51 std::allocator_arg_t, const test_allocator<int>&, 59 …std::tuple<ConvertibleFrom<ConstMove>> t2 = {std::allocator_arg, test_allocator<int>{}, std::move(… in test() 87 …std::tuple<ExplicitConstructibleFrom<ConstMove>, int> t2{std::allocator_arg_t{}, test_allocator<in… in test() 97 …rt(!std::is_constructible_v<std::tuple<int, int>, std::allocator_arg_t, const test_allocator<int>&, in test() 104 … const test_allocator<int>&, const std::tuple<int, int>&&>); in test() 117 std::tuple<TracedCopyMove> t2{std::allocator_arg_t{}, test_allocator<int>{}, std::move(t1)}; in test() 125 …std::tuple<TracedCopyMove, TracedCopyMove> t2{std::allocator_arg_t{}, test_allocator<int>{}, std::… in test() [all …]
|
| H A D | alloc_non_const_pair.pass.cpp | 33 …rt(std::is_constructible_v<std::tuple<MutableCopy, int>, std::allocator_arg_t, test_allocator<int>, 36 …ssert(!std::is_constructible_v< std::tuple<MutableCopy>, std::allocator_arg_t, test_allocator<int>, 39 …::is_constructible_v< std::tuple<MutableCopy, int, int>, std::allocator_arg_t, test_allocator<int>, 46 …std::is_constructible_v<std::tuple<int, int>, std::allocator_arg_t, test_allocator<int>, std::pair… 49 test_allocator<int>, std::pair<int, int>&>); 52 test_allocator<int>, std::pair<int, int>&>); 55 test_allocator<int>, std::pair<int, int>&>); 65 … std::allocator_arg_t, test_allocator<int>, std::pair<MutableCopy, MutableCopy>&>); 69 … std::allocator_arg_t, test_allocator<int>, std::pair<MutableCopy, MutableCopy>&>); 86 … test_allocator<int>{}, p}; in test() [all …]
|
| H A D | alloc_const_move_pair.pass.cpp | 33 …sert(std::is_constructible_v<std::tuple<ConstMove, int>, std::allocator_arg_t, test_allocator<int>, 36 static_assert(!std::is_constructible_v< std::tuple<ConstMove>, std::allocator_arg_t, test_allocator… 39 …td::is_constructible_v< std::tuple<ConstMove, int, int>, std::allocator_arg_t, test_allocator<int>, 45 static_assert(std::is_constructible_v<std::tuple<int, int>, std::allocator_arg_t, test_allocator<in… 49 test_allocator<int>, const std::pair<int, int>&&>); 52 test_allocator<int>, const std::pair<int, int>&&>); 55 test_allocator<int>, const std::pair<int, int>&&>); 62 test_allocator<int>, const std::pair<ConstMove, ConstMove>&&>); 76 …e<ConvertibleFrom<ConstMove>, ConvertibleFrom<int>> t = {std::allocator_arg, test_allocator<int>{}, in test() 88 std::allocator_arg, test_allocator<int>{}, std::move(p)}; in test() [all …]
|
| /llvm-project-15.0.7/libcxx/test/std/containers/sequences/vector/vector.cons/ |
| H A D | move_alloc.pass.cpp | 26 std::vector<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in tests() 27 std::vector<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in tests() 37 … std::vector<MoveOnly, test_allocator<MoveOnly> > l2(std::move(l), test_allocator<MoveOnly>(6)); in tests() 40 assert(l2.get_allocator() == test_allocator<MoveOnly>(6)); in tests() 44 std::vector<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in tests() 45 std::vector<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in tests() 55 … std::vector<MoveOnly, test_allocator<MoveOnly> > l2(std::move(l), test_allocator<MoveOnly>(5)); in tests() 58 assert(l2.get_allocator() == test_allocator<MoveOnly>(5)); in tests()
|
| H A D | assign_move.pass.cpp | 25 std::vector<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in tests() 26 std::vector<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in tests() 34 std::vector<MoveOnly, test_allocator<MoveOnly> > l2(test_allocator<MoveOnly>(5)); in tests() 42 std::vector<MoveOnly, test_allocator<MoveOnly> > l(test_allocator<MoveOnly>(5)); in tests() 43 std::vector<MoveOnly, test_allocator<MoveOnly> > lo(test_allocator<MoveOnly>(5)); in tests() 53 std::vector<MoveOnly, test_allocator<MoveOnly> > l2(test_allocator<MoveOnly>(6)); in tests() 57 assert(l2.get_allocator() == test_allocator<MoveOnly>(6)); in tests()
|
| /llvm-project-15.0.7/libcxx/test/support/ |
| H A D | test_allocator.h | 60 class test_allocator { 66 friend class test_allocator; variable 79 typedef test_allocator<U> other; 105 TEST_CONSTEXPR_CXX14 test_allocator(const test_allocator& a) TEST_NOEXCEPT in test_allocator() function 127 TEST_CONSTEXPR_CXX14 test_allocator(const test_allocator<U>& a) TEST_NOEXCEPT in test_allocator() function 178 …TEST_CONSTEXPR friend bool operator!=(const test_allocator& x, const test_allocator& y) { return !… 267 class test_allocator<void> { 273 friend class test_allocator; variable 284 typedef test_allocator<U> other; 303 TEST_CONSTEXPR_CXX14 explicit test_allocator(const test_allocator& a) TEST_NOEXCEPT in test_allocator() function [all …]
|
| /llvm-project-15.0.7/libcxx/test/std/containers/unord/unord.set/unord.set.cnstr/ |
| H A D | deduct.pass.cpp | 89 …std::unordered_set s(std::begin(arr), std::end(arr), 42, std::hash<long long>(), test_allocator<in… in main() 97 std::unordered_set<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 104 std::unordered_set<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 111 std::unordered_set<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 112 std::unordered_set s(source, test_allocator<int>(0, 41)); in main() 119 std::unordered_set<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 120 std::unordered_set s{source, test_allocator<int>(0, 42)}; // braces instead of parens in main() 164 std::unordered_set s(std::begin(arr), std::end(arr), 42, test_allocator<int>(0, 44)); in main() 173 …std::unordered_set s(std::begin(arr), std::end(arr), 42, std::hash<long long>(), test_allocator<in… in main() 181 std::unordered_set s({ 1, 2, 1, INT_MAX, 3 }, 42, test_allocator<int>(0, 43)); in main() [all …]
|
| /llvm-project-15.0.7/libcxx/test/std/containers/unord/unord.multiset/unord.multiset.cnstr/ |
| H A D | deduct.pass.cpp | 89 …multiset s(std::begin(arr), std::end(arr), 42, std::hash<long long>(), test_allocator<int>(0, 40)); in main() 97 std::unordered_multiset<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 104 std::unordered_multiset<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 111 std::unordered_multiset<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 112 std::unordered_multiset s(source, test_allocator<int>(0, 41)); in main() 119 std::unordered_multiset<int, std::hash<long long>, std::equal_to<>, test_allocator<int>> source; in main() 120 std::unordered_multiset s{source, test_allocator<int>(0, 42)}; // braces instead of parens in main() 164 std::unordered_multiset s(std::begin(arr), std::end(arr), 42, test_allocator<int>(0, 44)); in main() 173 …multiset s(std::begin(arr), std::end(arr), 42, std::hash<long long>(), test_allocator<int>(0, 44)); in main() 181 std::unordered_multiset s({ 1, 2, 1, INT_MAX, 3 }, 42, test_allocator<int>(0, 43)); in main() [all …]
|