aboutsummaryrefslogtreecommitdiff
path: root/lib/quotient_common.h
diff options
context:
space:
mode:
authorAlexey Rusakov <Kitsune-Ral@users.sf.net>2022-01-18 08:54:52 +0100
committerAlexey Rusakov <Kitsune-Ral@users.sf.net>2022-01-18 08:55:23 +0100
commitbd280a087ecab30f94f7937513ee298c233fcba1 (patch)
tree1209c5adc664e81e664b6be95f45dad86facdcf0 /lib/quotient_common.h
parentbc4a0f5d408d901f3c8f4dfeec0574ded04845bf (diff)
downloadlibquotient-bd280a087ecab30f94f7937513ee298c233fcba1.tar.gz
libquotient-bd280a087ecab30f94f7937513ee298c233fcba1.zip
Revise inline keyword usage
- Templates and constexpr imply inline - A function called from a single site better be inlined.
Diffstat (limited to 'lib/quotient_common.h')
-rw-r--r--lib/quotient_common.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/quotient_common.h b/lib/quotient_common.h
index 3d38ce1f..af3e2730 100644
--- a/lib/quotient_common.h
+++ b/lib/quotient_common.h
@@ -77,7 +77,7 @@ enum class Membership : unsigned int {
};
QUO_DECLARE_FLAGS_NS(MembershipMask, Membership)
-constexpr inline auto MembershipStrings = make_array(
+constexpr auto MembershipStrings = make_array(
// The order MUST be the same as the order in the original enum
"join", "leave", "invite", "knock", "ban");
@@ -95,7 +95,7 @@ enum class JoinState : std::underlying_type_t<Membership> {
};
QUO_DECLARE_FLAGS_NS(JoinStates, JoinState)
-constexpr inline auto JoinStateStrings = make_array(
+constexpr auto JoinStateStrings = make_array(
MembershipStrings[0], MembershipStrings[1], MembershipStrings[2],
MembershipStrings[3] /* same as MembershipStrings, sans "ban" */
);
@@ -125,9 +125,7 @@ enum RoomType {
};
Q_ENUM_NS(RoomType)
-constexpr inline auto RoomTypeStrings = make_array(
- "m.space"
-);
+constexpr auto RoomTypeStrings = make_array("m.space");
} // namespace Quotient
Q_DECLARE_OPERATORS_FOR_FLAGS(Quotient::MembershipMask)