Lines Matching refs:out
30 concept HasCopyIt = requires(In in, Sent sent, Out out) { std::ranges::copy(in, sent, out); };
43 concept HasCopyR = requires(Range range, Out out) { std::ranges::copy(range, out); };
61 std::array<int, 4> out; in test_iterators() local
63 std::ranges::copy(In(in.data()), Sent(In(in.data() + in.size())), Out(out.data())); in test_iterators()
64 assert(in == out); in test_iterators()
66 assert(base(ret.out) == out.data() + out.size()); in test_iterators()
70 std::array<int, 4> out; in test_iterators() local
72 …std::same_as<std::ranges::in_out_result<In, Out>> auto ret = std::ranges::copy(range, Out(out.data… in test_iterators()
73 assert(in == out); in test_iterators()
75 assert(base(ret.out) == out.data() + out.size()); in test_iterators()
82 std::array<int, 0> out; in test_iterators() local
83 auto ret = std::ranges::copy(In(in.data()), Sent(In(in.data() + in.size())), Out(out.data())); in test_iterators()
85 assert(base(ret.out) == out.data()); in test_iterators()
89 std::array<int, 0> out; in test_iterators() local
91 auto ret = std::ranges::copy(range, Out(out.data())); in test_iterators()
93 assert(base(ret.out) == out.data()); in test_iterators()
137 std::array<int, 4> out; in test() local
139 std::ranges::copy(std::array {1, 2, 3, 4}, out.data()); in test()
140 assert(ret.out == out.data() + 4); in test()
141 assert((out == std::array{1, 2, 3, 4})); in test()
146 std::array<int, 4> out; in test() local
147 …::ranges::in_out_result<int*, int*>> auto ret = std::ranges::copy(std::views::all(in), out.data()); in test()
149 assert(ret.out == out.data() + 4); in test()
150 assert(in == out); in test()
166 std::array<CopyOnce, 4> out {}; in test() local
167 auto ret = std::ranges::copy(in.begin(), in.end(), out.begin()); in test()
169 assert(ret.out == out.end()); in test()
170 assert(std::all_of(out.begin(), out.end(), [](const auto& e) { return e.copied; })); in test()
174 std::array<CopyOnce, 4> out {}; in test() local
175 auto ret = std::ranges::copy(in, out.begin()); in test()
177 assert(ret.out == out.end()); in test()
178 assert(std::all_of(out.begin(), out.end(), [](const auto& e) { return e.copied; })); in test()
196 std::array<OnlyForwardsCopyable, 3> out {}; in test() local
197 out[0].next = &out[1]; in test()
198 out[1].next = &out[2]; in test()
199 out[0].canCopy = true; in test()
200 auto ret = std::ranges::copy(in.begin(), in.end(), out.begin()); in test()
202 assert(ret.out == out.end()); in test()
203 assert(out[0].canCopy); in test()
204 assert(out[1].canCopy); in test()
205 assert(out[2].canCopy); in test()
209 std::array<OnlyForwardsCopyable, 3> out {}; in test() local
210 out[0].next = &out[1]; in test()
211 out[1].next = &out[2]; in test()
212 out[0].canCopy = true; in test()
213 auto ret = std::ranges::copy(in, out.begin()); in test()
215 assert(ret.out == out.end()); in test()
216 assert(out[0].canCopy); in test()
217 assert(out[1].canCopy); in test()
218 assert(out[2].canCopy); in test()