Commit 79dc0f23 authored by dmauro's avatar dmauro Committed by Derek Mauro
Browse files

Googletest export

Disable -Wmismatched-tags warning for struct/class tuple_size

PiperOrigin-RevId: 337087493
parent b2cb220e
...@@ -1323,11 +1323,19 @@ constexpr bool InstantiateTypedTestCase_P_IsDeprecated() { return true; } ...@@ -1323,11 +1323,19 @@ constexpr bool InstantiateTypedTestCase_P_IsDeprecated() { return true; }
} // namespace testing } // namespace testing
namespace std { namespace std {
// Some standard library implementations use `struct tuple_size` and some use
// `class tuple_size`. Clang warns about the mismatch.
// https://reviews.llvm.org/D55466
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wmismatched-tags"
#endif
template <typename... Ts> template <typename... Ts>
class tuple_size<testing::internal::FlatTuple<Ts...>> struct tuple_size<testing::internal::FlatTuple<Ts...>>
: public std::integral_constant<size_t, sizeof...(Ts)> {}; : std::integral_constant<size_t, sizeof...(Ts)> {};
#ifdef __clang__
#pragma clang diagnostic pop
#endif
} // namespace std } // namespace std
#define GTEST_MESSAGE_AT_(file, line, message, result_type) \ #define GTEST_MESSAGE_AT_(file, line, message, result_type) \
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment