prefer std::format over fmt
Use std::format or stdplus::print and eliminate the fmt dependency.
Change-Id: Ide14b682949914f09f749141196cdb210fe1239e
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/src/rde/rde_dictionary_manager.cpp b/src/rde/rde_dictionary_manager.cpp
index c3567fb..0904fad 100644
--- a/src/rde/rde_dictionary_manager.cpp
+++ b/src/rde/rde_dictionary_manager.cpp
@@ -1,6 +1,8 @@
#include "rde/rde_dictionary_manager.hpp"
-#include <fmt/format.h>
+#include <stdplus/print.hpp>
+
+#include <format>
namespace bios_bmc_smm_error_logger
{
@@ -36,7 +38,7 @@
auto itemIt = dictionaries.find(resourceId);
if (itemIt == dictionaries.end())
{
- fmt::print(stderr, "Resource ID {} not found.\n", resourceId);
+ stdplus::print(stderr, "Resource ID {} not found.\n", resourceId);
return false;
}
validateDictionaryEntry(*itemIt->second);
@@ -49,7 +51,7 @@
auto itemIt = dictionaries.find(resourceId);
if (itemIt == dictionaries.end())
{
- fmt::print(stderr, "Resource ID {} not found.\n", resourceId);
+ stdplus::print(stderr, "Resource ID {} not found.\n", resourceId);
return false;
}
// Since we are modifying an existing entry, invalidate the existing entry.
@@ -65,15 +67,15 @@
auto itemIt = dictionaries.find(resourceId);
if (itemIt == dictionaries.end())
{
- fmt::print(stderr, "Resource ID {} not found.\n", resourceId);
+ stdplus::print(stderr, "Resource ID {} not found.\n", resourceId);
return std::nullopt;
}
if (!itemIt->second->valid)
{
- fmt::print(stderr,
- "Requested an incomplete dictionary. Resource ID {}\n",
- resourceId);
+ stdplus::print(stderr,
+ "Requested an incomplete dictionary. Resource ID {}\n",
+ resourceId);
return std::nullopt;
}
return itemIt->second->data;