prefer std::format over fmt
Since C++20, std::format has existed so prefer that. For the single
fmt::print call we can use stdplus::print until GCC supports the std
one.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I4c8af58966fb7330dee20fb13ae2ef11d8a823c7
diff --git a/fan_pwm.cpp b/fan_pwm.cpp
index 253515d..6e903d3 100644
--- a/fan_pwm.cpp
+++ b/fan_pwm.cpp
@@ -6,12 +6,11 @@
#include "sensorset.hpp"
#include "sysfs.hpp"
-#include <fmt/format.h>
-
#include <phosphor-logging/elog-errors.hpp>
#include <xyz/openbmc_project/Control/Device/error.hpp>
#include <filesystem>
+#include <format>
#include <string>
using namespace phosphor::logging;
@@ -42,7 +41,7 @@
auto file = sysfs::make_sysfs_path(_ioAccess->path(), _type, _id,
empty);
- log<level::INFO>(fmt::format("Failing sysfs file: {} errno: {}", file,
+ log<level::INFO>(std::format("Failing sysfs file: {} errno: {}", file,
e.code().value())
.c_str());