From 9086231f3923c0df6d9ef817441bfae5e134e8ff Mon Sep 17 00:00:00 2001 From: Martin Ridgers Date: Mon, 10 Jan 2022 12:07:03 +0100 Subject: Converted use of _format UDL to fmt::format --- zenstore/basicfile.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'zenstore/basicfile.cpp') diff --git a/zenstore/basicfile.cpp b/zenstore/basicfile.cpp index 41d296cbb..dcd9a8575 100644 --- a/zenstore/basicfile.cpp +++ b/zenstore/basicfile.cpp @@ -23,8 +23,6 @@ namespace zen { -using namespace fmt::literals; - BasicFile::~BasicFile() { Close(); @@ -38,7 +36,7 @@ BasicFile::Open(std::filesystem::path FileName, bool IsCreate) if (Ec) { - throw std::system_error(Ec, "failed to open file '{}'"_format(FileName)); + throw std::system_error(Ec, fmt::format("failed to open file '{}'", FileName)); } } @@ -133,7 +131,7 @@ BasicFile::Read(void* Data, uint64_t BytesToRead, uint64_t FileOffset) if (!Success) { - ThrowLastError("Failed to read from file '{}'"_format(zen::PathFromHandle(m_FileHandle))); + ThrowLastError(fmt::format("Failed to read from file '{}'", zen::PathFromHandle(m_FileHandle))); } BytesToRead -= NumberOfBytesToRead; @@ -239,7 +237,7 @@ BasicFile::Write(const void* Data, uint64_t Size, uint64_t Offset) if (Ec) { - throw std::system_error(Ec, "Failed to write to file '{}'"_format(zen::PathFromHandle(m_FileHandle))); + throw std::system_error(Ec, fmt::format("Failed to write to file '{}'", zen::PathFromHandle(m_FileHandle))); } } -- cgit v1.2.3