Home
last modified time | relevance | path

Searched refs:Tuple (Results 1 – 25 of 106) sorted by relevance

12345

/llvm-project/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.apply/
H A Dmake_from_tuple.pass.cpp13 // template <class T, class Tuple> constexpr T make_from_tuple(Tuple&&);
25 template <class Tuple>
30 Tuple args;
36 template <template <class ...> class Tuple, class ...Types>
37 struct ConstructibleFromTuple<Tuple<Types...>> {
43 Tuple<std::decay_t<Types>...> args;
58 template <class Tuple> in do_constexpr_test()
59 constexpr bool do_constexpr_test(Tuple&& tup) { in do_constexpr_test()
60 using RawTuple = std::decay_t<Tuple>; in do_constexpr_test()
91 using Tuple = std::array<int, 3>; test_constexpr_construction() typedef
163 using Tuple = std::tuple<int, NothrowMoveable>; test_noexcept() typedef
170 using Tuple = std::pair<int, NothrowMoveable>; test_noexcept() typedef
177 using Tuple = std::tuple<int, int, int>; test_noexcept() typedef
182 using Tuple = std::tuple<long, long, long>; test_noexcept() typedef
187 using Tuple = std::array<int, 3>; test_noexcept() typedef
192 using Tuple = std::array<long, 3>; test_noexcept() typedef
[all...]
/llvm-project/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.creation/
H A Dforward_as_tuple.pass.cpp22 template <class Tuple>
24 test0(const Tuple&) in test0() argument
26 static_assert(std::tuple_size<Tuple>::value == 0, ""); in test0()
29 template <class Tuple>
31 test1a(const Tuple& t) in test1a()
33 static_assert(std::tuple_size<Tuple>::value == 1, ""); in test1a()
34 static_assert(std::is_same<typename std::tuple_element<0, Tuple>::type, int&&>::value, ""); in test1a()
38 template <class Tuple>
40 test1b(const Tuple& t) in test1b()
42 static_assert(std::tuple_size<Tuple>::value == 1, ""); in test1b()
[all …]
/llvm-project/libcxx/test/libcxx/utilities/tuple/tuple.tuple/tuple.assign/
H A Darray.extension.pass.cpp50 typedef std::tuple<NothrowAssignableFrom<int>> Tuple; in main() typedef
52 static_assert(std::is_nothrow_assignable<Tuple&, Array const&>::value, ""); in main()
55 typedef std::tuple<PotentiallyThrowingAssignableFrom<int>> Tuple; in main() typedef
57 static_assert(std::is_assignable<Tuple&, Array const&>::value, ""); in main()
58 static_assert(!std::is_nothrow_assignable<Tuple&, Array const&>::value, ""); in main()
71 typedef std::tuple<NothrowAssignableFrom<int>> Tuple; in main() typedef
73 static_assert(std::is_nothrow_assignable<Tuple&, Array&&>::value, ""); in main()
76 typedef std::tuple<PotentiallyThrowingAssignableFrom<int>> Tuple; in main() typedef
78 static_assert(std::is_assignable<Tuple&, Array&&>::value, ""); in main()
79 static_assert(!std::is_nothrow_assignable<Tuple&, Array&&>::value, ""); in main()
[all …]
/llvm-project/libcxx/test/std/concepts/concepts.lang/concept.assignable/
H A Dassignable_from.compile.pass.cpp78 struct Tuple { struct
79 Tuple& operator=(const Tuple&);
80 const Tuple& operator=(const Tuple&) const;
82 static_assert(!std::assignable_from<Tuple, const Tuple&>);
83 static_assert( std::assignable_from<Tuple&, const Tuple&>);
84 static_assert(!std::assignable_from<Tuple&&, const Tuple&>);
85 static_assert(!std::assignable_from<const Tuple, const Tuple&>);
86 static_assert( std::assignable_from<const Tuple&, const Tuple&>);
87 static_assert(!std::assignable_from<const Tuple&&, const Tuple&>);
/llvm-project/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.helper/
H A Dtuple_size_v.pass.cpp21 template <class Tuple, int Expect>
24 static_assert(std::tuple_size_v<Tuple> == Expect, ""); in test()
25 static_assert(std::tuple_size_v<Tuple> == std::tuple_size<Tuple>::value, ""); in test()
26 static_assert(std::tuple_size_v<Tuple const> == std::tuple_size<Tuple>::value, ""); in test()
27 static_assert(std::tuple_size_v<Tuple volatile> == std::tuple_size<Tuple>::value, ""); in test()
28 static_assert(std::tuple_size_v<Tuple const volatile> == std::tuple_size<Tuple>::value, ""); in test()
/llvm-project/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.assign/
H A Dconst_pair.pass.cpp65 typedef std::tuple<NothrowCopyAssignable, long> Tuple; in main() typedef
67 static_assert(std::is_nothrow_assignable<Tuple&, Pair const&>::value, ""); in main()
68 static_assert(std::is_nothrow_assignable<Tuple&, Pair&>::value, ""); in main()
69 static_assert(std::is_nothrow_assignable<Tuple&, Pair const&&>::value, ""); in main()
72 typedef std::tuple<PotentiallyThrowingCopyAssignable, long> Tuple; in main() typedef
74 static_assert(std::is_assignable<Tuple&, Pair const&>::value, ""); in main()
75 static_assert(!std::is_nothrow_assignable<Tuple&, Pair const&>::value, ""); in main()
77 static_assert(std::is_assignable<Tuple&, Pair&>::value, ""); in main()
78 static_assert(!std::is_nothrow_assignable<Tuple&, Pair&>::value, ""); in main()
80 static_assert(std::is_assignable<Tuple&, Pair const&&>::value, ""); in main()
[all …]
H A Dmove_pair.pass.cpp114 typedef std::tuple<NothrowMoveAssignable, long> Tuple; in main() typedef
116 static_assert(std::is_nothrow_assignable<Tuple&, Pair&&>::value, ""); in main()
117 static_assert(!std::is_assignable<Tuple&, Pair const&&>::value, ""); in main()
120 typedef std::tuple<PotentiallyThrowingMoveAssignable, long> Tuple; in main() typedef
122 static_assert(std::is_assignable<Tuple&, Pair&&>::value, ""); in main()
123 static_assert(!std::is_nothrow_assignable<Tuple&, Pair&&>::value, ""); in main()
124 static_assert(!std::is_assignable<Tuple&, Pair const&&>::value, ""); in main()
/llvm-project/clang/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.partial/
H A Dp12.cpp6 template<class ...> struct Tuple { }; struct
7 template<class ... Types> int &g(Tuple<Types ...>); // #1
8 template<class T1, class ... Types> float &g(Tuple<T1, Types ...>); // #2
9 template<class T1, class ... Types> double &g(Tuple<T1, Types& ...>); // #3
12 int &ir1 = g(Tuple<>()); in test_g()
13 float &fr1 = g(Tuple<int, float>()); in test_g()
14 double &dr1 = g(Tuple<int, float&>()); in test_g()
15 double &dr2 = g(Tuple<int>()); in test_g()
/llvm-project/compiler-rt/lib/xray/
H A Dxray_fdr_log_writer.h25 template <class Tuple,
28 typename std::remove_reference<Tuple>::type>::value,
30 Tuple &&T) {
35 std::forward<Tuple>(T));
38 template <class Tuple,
41 Tuple>::type>::value,
43 static void serializeTo(char *, Tuple &&) {} in serializeTo()
48 template <class Tuple, size_t Index> struct AggregateSizesImpl {
50 sizeof(typename std::tuple_element<Index, Tuple>::type) +
51 AggregateSizesImpl<Tuple, Index - 1>::value;
[all …]
/llvm-project/libcxx/test/std/utilities/tuple/tuple.tuple/tuple.cnstr/
H A DUTypes.pass.cpp44 typedef std::tuple<MoveOnly, NoDefault> Tuple; in test_sfinae_missing_elements() typedef
47 Tuple, in test_sfinae_missing_elements()
52 Tuple, in test_sfinae_missing_elements()
57 typedef std::tuple<MoveOnly, MoveOnly, NoDefault> Tuple; in test_sfinae_missing_elements() typedef
60 Tuple, in test_sfinae_missing_elements()
65 Tuple, in test_sfinae_missing_elements()
71 typedef std::tuple<MoveOnly, NoDefault> Tuple; in test_sfinae_missing_elements() typedef
72 typedef std::tuple<MoveOnly, Tuple, MoveOnly, MoveOnly> NestedTuple; in test_sfinae_missing_elements()
81 MoveOnly, Tuple, MoveOnly, MoveOnly in test_sfinae_missing_elements()
H A DPR22806_constrain_tuple_like_ctor.pass.cpp30 template <class Tuple, class = uncvref_t<Tuple>>
33 template <class Tuple, class ...Args>
34 struct IsTuple<Tuple, std::tuple<Args...>> : std::true_type {};
43 template <class Tuple, class = typename std::enable_if<IsTuple<Tuple>::value>::type>
44 explicit ConstructibleFromTupleAndInt(Tuple&&) : state(FromTuple) {} in ConstructibleFromTupleAndInt()
56 template <class Tuple, class = typename std::enable_if<IsTuple<Tuple>::value>::type>
57 ConvertibleFromTupleAndInt(Tuple&&) : state(FromTuple) {} in ConvertibleFromTupleAndInt()
H A Dalloc_UTypes.pass.cpp48 typedef std::tuple<MoveOnly, MoveOnly, BadDefault> Tuple; in test_uses_allocator_sfinae_evaluation() typedef
51 Tuple, in test_uses_allocator_sfinae_evaluation()
56 Tuple, in test_uses_allocator_sfinae_evaluation()
61 typedef std::tuple<MoveOnly, MoveOnly, BadDefault, BadDefault> Tuple; in test_uses_allocator_sfinae_evaluation() typedef
64 Tuple, in test_uses_allocator_sfinae_evaluation()
69 Tuple, in test_uses_allocator_sfinae_evaluation()
/llvm-project/llvm/lib/IR/
H A DProfileSummary.cpp181 static bool getOptionalVal(MDTuple *Tuple, unsigned &Idx, const char *Key, in getOptionalVal() argument
183 if (getVal(dyn_cast<MDTuple>(Tuple->getOperand(Idx)), Key, Value)) { in getOptionalVal()
186 // of Tuple operand array. Since (non-optional) DetailedSummary always comes in getOptionalVal()
188 return Idx < Tuple->getNumOperands(); in getOptionalVal()
195 MDTuple *Tuple = dyn_cast_or_null<MDTuple>(MD); in getFromMD() local
196 if (!Tuple || Tuple->getNumOperands() < 8 || Tuple->getNumOperands() > 10) in getFromMD()
200 auto &FormatMD = Tuple->getOperand(I++); in getFromMD()
216 if (!getVal(dyn_cast<MDTuple>(Tuple in getFromMD()
[all...]
H A DMemoryModelRelaxationAnnotations.cpp29 MDTuple *Tuple = dyn_cast<MDTuple>(MD); in MMRAMetadata()
30 assert(Tuple && "Invalid MMRA structure"); in MMRAMetadata() local
37 if (isTagMD(Tuple)) { in MMRAMetadata()
38 HandleTagMD(Tuple); in MMRAMetadata()
42 for (const MDOperand &Op : Tuple->operands()) { in MMRAMetadata()
50 if (auto *Tuple = dyn_cast<MDTuple>(MD)) { in isTagMD()
51 return Tuple->getNumOperands() == 2 && in isTagMD() local
52 isa<MDString>(Tuple->getOperand(0)) && in isTagMD()
53 isa<MDString>(Tuple->getOperand(1)); in isTagMD()
/llvm-project/clang/test/AST/Interp/
H A Dcxx17.cpp
/llvm-project/clang/test/CXX/temp/temp.decls/temp.variadic/
H A Dp1.cpp3 template<class ...Types> struct Tuple;
5 Tuple<> *t0;
6 Tuple<int> *t1;
7 Tuple<int, char> *t2a;
8 Tuple<int, float> *t2b = t2a; // expected-error{{cannot initialize a variable of type 'Tuple<int, f…
9 Tuple<int, float, double> *t3;
/llvm-project/llvm/include/llvm/ADT/
H A DDenseMapInfo.h257 using Tuple = std::tuple<Ts...>;
259 static inline Tuple getEmptyKey() {
260 return Tuple(DenseMapInfo<Ts>::getEmptyKey()...);
263 static inline Tuple getTombstoneKey() {
264 return Tuple(DenseMapInfo<Ts>::getTombstoneKey()...);
268 static unsigned getHashValueImpl(const Tuple &values, std::false_type) {
269 using EltType = std::tuple_element_t<I, Tuple>;
277 static unsigned getHashValueImpl(const Tuple &, std::true_type) {
287 static bool isEqualImpl(const Tuple &lhs, const Tuple &rhs, std::false_type) {
288 using EltType = std::tuple_element_t<I, Tuple>;
[all …]
/llvm-project/mlir/test/mlir-pdll/Parser/
H A Dconstraint.pdll4 // CHECK: `-UserConstraintDecl {{.*}} Name<Foo> ResultType<Tuple<>>
10 // CHECK: `-UserConstraintDecl {{.*}} Name<Foo> ResultType<Tuple<>> Code< /* Native Code */ >
38 // CHECK: `-UserConstraintDecl {{.*}} Name<Foo> ResultType<Tuple<result1: Value, result2: Attr>>
48 // CHECK: `-TupleExpr {{.*}} Type<Tuple<result1: Value, result2: Attr>>
50 // CHECK: | `-TupleExpr {{.*}} Type<Tuple<Value, Attr>>
52 // CHECK: `-TupleExpr {{.*}} Type<Tuple<Value, Attr>>
58 // CHECK: |-UserConstraintDecl {{.*}} Name<Bar> ResultType<Tuple<>>
63 // CHECK: `-UserConstraintDecl {{.*}} Name<Bar> ResultType<Tuple<>>
67 // CHECK: `-UserConstraintDecl {{.*}} Name<Bar> ResultType<Tuple<>>
77 // CHECK: UserConstraintDecl {{.*}} Name<<anonymous_constraint_0>> ResultType<Tuple<>>
H A Drewrite.pdll4 // CHECK: `-UserRewriteDecl {{.*}} Name<Foo> ResultType<Tuple<>>
10 // CHECK: `-UserRewriteDecl {{.*}} Name<Foo> ResultType<Tuple<>> Code< /* Native Code */ >
31 // CHECK: `-UserRewriteDecl {{.*}} Name<Foo> ResultType<Tuple<result1: Value, result2: Attr>>
41 // CHECK: `-TupleExpr {{.*}} Type<Tuple<result1: Value, result2: Attr>>
43 // CHECK: | `-TupleExpr {{.*}} Type<Tuple<Value, Attr>>
45 // CHECK: `-TupleExpr {{.*}} Type<Tuple<Value, Attr>>
53 // CHECK: UserRewriteDecl {{.*}} Name<<anonymous_rewrite_0>> ResultType<Tuple<>>
/llvm-project/llvm/unittests/Support/
H A DReverseIterationTest.cpp49 for (auto Tuple : zip(Map, IterKeys)) in TEST() local
50 ASSERT_EQ(std::get<0>(Tuple).first, std::get<1>(Tuple)); in TEST()
103 for (auto Tuple : zip(Map, Keys)) in TEST() local
104 ASSERT_EQ(std::get<0>(Tuple).second, std::get<1>(Tuple)->value); in TEST()
/llvm-project/llvm/tools/llvm-jitlistener/
H A Dllvm-jitlistener.cpp165 Triple Tuple(TheModule->getTargetTriple()); in InitEE() local
166 if (Tuple.getTriple().empty()) in InitEE()
167 Tuple.setTriple(sys::getProcessTriple()); in InitEE()
169 if (Tuple.isOSWindows() && !Tuple.isOSBinFormatELF()) { in InitEE()
170 Tuple.setObjectFormat(Triple::ELF); in InitEE()
171 TheModule->setTargetTriple(Tuple.getTriple()); in InitEE()
/llvm-project/libcxx/test/std/utilities/meta/meta.unary/meta.unary.prop/
H A Dis_nothrow_constructible.pass.cpp71 struct Tuple { struct
72 Tuple(Empty&&) noexcept {} in Tuple() function
88 test_is_nothrow_constructible<Tuple &&, Empty> (); // See bug #19616. in main()
90 static_assert(!std::is_constructible<Tuple&, Empty>::value, ""); in main()
91 test_is_not_nothrow_constructible<Tuple &, Empty> (); // See bug #19616. in main()
/llvm-project/llvm/test/CodeGen/Generic/
H A Dpr33094.ll9 %Tuple = type { i64 }
16 %s = select i1 %c, %Tuple { i64 33 }, %Tuple { i64 42 }
17 %e = extractvalue %Tuple %s, 0
/llvm-project/libcxx/test/std/utilities/utility/utility.intcmp/intcmp.in_range/
H A Din_range.pass.cpp26 struct Tuple { struct
30 constexpr Tuple() { in Tuple() argument
39 constexpr Tuple<T> tup; in test_in_range1()
50 constexpr Tuple<std::uint8_t> utup8; in test_in_range()
51 constexpr Tuple<std::int8_t> stup8; in test_in_range()
/llvm-project/third-party/unittest/googlemock/include/gmock/internal/
H A Dgmock-internal-utils.h422 template <typename F, typename Tuple, size_t... Idx>
423 auto ApplyImpl(F&& f, Tuple&& args, IndexSequence<Idx...>)
425 std::get<Idx>(std::forward<Tuple>(args))...)) {
426 return std::forward<F>(f)(std::get<Idx>(std::forward<Tuple>(args))...);
430 template <typename F, typename Tuple>
431 auto Apply(F&& f, Tuple&& args) -> decltype(ApplyImpl(
432 std::forward<F>(f), std::forward<Tuple>(args),
434 typename std::remove_reference<Tuple>::type>::value>())) {
435 return ApplyImpl(std::forward<F>(f), std::forward<Tuple>(args),
437 typename std::remove_reference<Tuple>::type>::value>());

12345