From a44622aa9ff4b85c5eeb54663ecf9d7fe617bc08 Mon Sep 17 00:00:00 2001 From: Aleksei Bavshin Date: Wed, 13 Jul 2022 22:34:29 -0700 Subject: [PATCH] fix: fmt 9.x deprecation warning for implicit enum conversions --- src/modules/mpd/state.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/modules/mpd/state.cpp b/src/modules/mpd/state.cpp index 4d1e8c91..aa1a18f8 100644 --- a/src/modules/mpd/state.cpp +++ b/src/modules/mpd/state.cpp @@ -10,6 +10,13 @@ namespace waybar::modules { } // namespace waybar::modules #endif +#if FMT_VERSION >= 90000 +/* Satisfy fmt 9.x deprecation of implicit conversion of enums to int */ +auto format_as(enum mpd_idle val) { + return static_cast>(val); +} +#endif + namespace waybar::modules::detail { #define IDLE_RUN_NOIDLE_AND_CMD(...) \