Lines Matching refs:tup
63 constexpr bool do_constexpr_test(Tuple&& tup) {
66 return std::make_from_tuple<Tp>(std::forward<Tuple>(tup)).args == tup;
76 bool do_forwarding_test(Tuple&& tup) {
79 const Tp value = std::make_from_tuple<Tp>(std::forward<Tuple>(tup));
80 return value.args == tup
86 constexpr std::tuple<> tup;
87 static_assert(do_constexpr_test(tup), "");
90 constexpr std::tuple<int> tup(42);
91 static_assert(do_constexpr_test(tup), "");
94 constexpr std::tuple<int, long, void*> tup(42, 101, nullptr);
95 static_assert(do_constexpr_test(tup), "");
113 using Tup = std::tuple<>;
114 Tup tup;
115 Tup const& ctup = tup;
116 assert(do_forwarding_test<>(tup));
120 using Tup = std::tuple<int>;
121 Tup tup(42);
122 Tup const& ctup = tup;
123 assert(do_forwarding_test<int&>(tup));
125 assert(do_forwarding_test<int&&>(std::move(tup)));
129 using Tup = std::tuple<int&, const char*, unsigned&&>;
132 Tup tup(x, "hello world", std::move(y));
133 Tup const& ctup = tup;
134 assert((do_forwarding_test<int&, const char*&, unsigned&>(tup)));
136 assert((do_forwarding_test<int&, const char*&&, unsigned&&>(std::move(tup))));
141 using Tup = std::pair<int&, const char*>;
143 Tup tup(x, "hello world");
144 Tup const& ctup = tup;
145 assert((do_forwarding_test<int&, const char*&>(tup)));
147 assert((do_forwarding_test<int&, const char*&&>(std::move(tup))));
152 using Tup = std::array<int, 3>;
153 Tup tup = {42, 101, -1};
154 Tup const& ctup = tup;
155 assert((do_forwarding_test<int&, int&, int&>(tup)));
157 assert((do_forwarding_test<int&&, int&&, int&&>(std::move(tup))));
175 Tuple tup; ((void)tup);
176 Tuple const& ctup = tup; ((void)ctup);
178 LIBCPP_ASSERT_NOEXCEPT(std::make_from_tuple<TestType>(std::move(tup)));
182 Tuple tup; ((void)tup);
183 Tuple const& ctup = tup; ((void)ctup);
185 LIBCPP_ASSERT_NOEXCEPT(std::make_from_tuple<TestType>(std::move(tup)));
189 Tuple tup; ((void)tup);
190 ASSERT_NOT_NOEXCEPT(std::make_from_tuple<TestType>(tup));
194 Tuple tup; ((void)tup);
195 LIBCPP_ASSERT_NOEXCEPT(std::make_from_tuple<TestType>(tup));
199 Tuple tup; ((void)tup);
200 ASSERT_NOT_NOEXCEPT(std::make_from_tuple<TestType>(tup));
204 Tuple tup; ((void)tup);
205 LIBCPP_ASSERT_NOEXCEPT(std::make_from_tuple<TestType>(tup));