fix(util): make waybar_time formatter compatible with fmt 8.1.0

Stop using private implementation details of the `formatter<std::tm>`.
We never needed anything from the class besides the format specifier,
which is easily obtainable with public API.
This commit is contained in:
Aleksei Bavshin
2022-01-07 22:25:15 -08:00
parent 1489a539f8
commit 7f6bef2049
2 changed files with 28 additions and 12 deletions

View File

@ -1,10 +1,16 @@
#include "modules/clock.hpp"
#include <time.h>
#include <spdlog/spdlog.h>
#if FMT_VERSION < 60000
#include <fmt/time.h>
#else
#include <fmt/chrono.h>
#endif
#include <ctime>
#include <sstream>
#include <type_traits>
#include "util/ustring_clen.hpp"
#include "util/waybar_time.hpp"
#ifdef HAVE_LANGINFO_1STDAY