Use fmt::format_string

This commit is contained in:
Pokechu22 2022-01-12 16:59:19 -08:00
parent ff8965c40b
commit 0cc211d1ef
2 changed files with 3 additions and 3 deletions

View File

@ -101,7 +101,7 @@ void FSDevice::DoState(PointerWrap& p)
}
template <typename... Args>
static void LogResult(ResultCode code, std::string_view format, Args&&... args)
static void LogResult(ResultCode code, fmt::format_string<Args...> format, Args&&... args)
{
const std::string command = fmt::format(format, std::forward<Args>(args)...);
const auto type =
@ -112,7 +112,7 @@ static void LogResult(ResultCode code, std::string_view format, Args&&... args)
}
template <typename T, typename... Args>
static void LogResult(const Result<T>& result, std::string_view format, Args&&... args)
static void LogResult(const Result<T>& result, fmt::format_string<Args...> format, Args&&... args)
{
const auto result_code = result.Succeeded() ? ResultCode::Success : result.Error();
LogResult(result_code, format, std::forward<Args>(args)...);

View File

@ -107,7 +107,7 @@ public:
// Writes format strings using fmtlib format strings.
template <typename... Args>
void Write(std::string_view format, Args&&... args)
void Write(fmt::format_string<Args...> format, Args&&... args)
{
fmt::format_to(std::back_inserter(m_buffer), format, std::forward<Args>(args)...);
}