From 574497cfc556eac00d1d9ac3d198028aa13b962d Mon Sep 17 00:00:00 2001 From: Arthur O'Dwyer Date: Wed, 18 Oct 2023 15:03:52 -0400 Subject: [PATCH] [test] Silence some GCC warnings-as-errors --- test/hive_test.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/test/hive_test.cpp b/test/hive_test.cpp index 52b9c92..90bd3ac 100644 --- a/test/hive_test.cpp +++ b/test/hive_test.cpp @@ -1976,6 +1976,8 @@ TYPED_TEST(hivet, MoveOnlyInputIterator) using Hive = TypeParam; using Value = typename Hive::value_type; +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wunused-local-typedefs" struct MoveOnlyInputIterator { using value_type = Value; using difference_type = signed char; @@ -1990,11 +1992,10 @@ TYPED_TEST(hivet, MoveOnlyInputIterator) auto& operator++() { ++p_; return *this; } void operator++(int) { ++p_; } bool operator==(const MoveOnlyInputIterator& rhs) const { return p_ == rhs.p_; } - bool operator==(const Value *p) const { return p_ == p; } -#if __cplusplus < 202002L bool operator!=(const MoveOnlyInputIterator& rhs) const { return p_ != rhs.p_; } -#endif + bool operator==(const Value *p) const { return p_ == p; } }; +#pragma GCC diagnostic pop static_assert(std::is_move_constructible::value); static_assert(!std::is_copy_constructible::value);