From b17b629df44dbc888f6b6bee79d0d13d662371cf Mon Sep 17 00:00:00 2001 From: Alexey Rusakov Date: Tue, 18 Jan 2022 08:55:10 +0100 Subject: Add [[maybe_unused]] to things the lib doesn't use --- lib/function_traits.cpp | 2 +- lib/quotient_common.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/function_traits.cpp b/lib/function_traits.cpp index 20bcf30e..6542101a 100644 --- a/lib/function_traits.cpp +++ b/lib/function_traits.cpp @@ -47,7 +47,7 @@ static_assert(std::is_same_v, int>, "Test fn_arg_t defaulting to first argument"); template -static void ft(const std::vector&); +[[maybe_unused]] static void ft(const std::vector&); static_assert( std::is_same)>, const std::vector&>(), "Test function templates"); diff --git a/lib/quotient_common.h b/lib/quotient_common.h index af3e2730..02a9f0cd 100644 --- a/lib/quotient_common.h +++ b/lib/quotient_common.h @@ -95,7 +95,7 @@ enum class JoinState : std::underlying_type_t { }; QUO_DECLARE_FLAGS_NS(JoinStates, JoinState) -constexpr auto JoinStateStrings = make_array( +[[maybe_unused]] constexpr auto JoinStateStrings = make_array( MembershipStrings[0], MembershipStrings[1], MembershipStrings[2], MembershipStrings[3] /* same as MembershipStrings, sans "ban" */ ); @@ -125,7 +125,7 @@ enum RoomType { }; Q_ENUM_NS(RoomType) -constexpr auto RoomTypeStrings = make_array("m.space"); +[[maybe_unused]] constexpr auto RoomTypeStrings = make_array("m.space"); } // namespace Quotient Q_DECLARE_OPERATORS_FOR_FLAGS(Quotient::MembershipMask) -- cgit v1.2.3