From 3497449a37f36d54b7897760eeabe496ae165ad8 Mon Sep 17 00:00:00 2001 From: "Stephan T. Lavavej" Date: Tue, 20 Jun 2017 21:10:53 +0000 Subject: [PATCH] [libcxx] [test] Fix -Wmismatched-tags in tuple_size_structured_bindings.pass.cpp. Clang and C1XX both complain about mismatched class/struct, but libc++ and MSVC's STL differ on what they use for tuple_element/tuple_size, so there's no way to win here. I'm reverting this part of my previous change. In the future, I'll have to suppress the warning for one compiler or the other. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@305854 91177308-0d34-0410-b5e6-96231b3b80d8 --- .../tuple.helper/tuple_size_structured_bindings.pass.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_size_structured_bindings.pass.cpp b/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_size_structured_bindings.pass.cpp index fdd60663c..03fb78caa 100644 --- a/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_size_structured_bindings.pass.cpp +++ b/test/std/utilities/tuple/tuple.tuple/tuple.helper/tuple_size_structured_bindings.pass.cpp @@ -117,7 +117,8 @@ template int get(Test const&) { static_assert(N == 0, ""); return -1; } template <> -struct std::tuple_element<0, Test> { +class std::tuple_element<0, Test> { +public: typedef int type; }; @@ -128,7 +129,8 @@ void test_before_tuple_size_specialization() { } template <> -struct std::tuple_size { +class std::tuple_size { +public: static const size_t value = 1; };