summaryrefslogtreecommitdiffhomepage
path: root/compat
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2023-04-16 12:24:19 +0200
committerStanislaw Halik <sthalik@misaki.pl>2023-04-16 13:44:15 +0200
commit5e9a9fef6edb636b7e6babb743541a18f25bd67f (patch)
tree0ffef80b2781498a80a8ddcf6d20c9cede749239 /compat
parentd2932dbdcf1ee0e646be90d9ad631ced171e012b (diff)
use Corrade::Utility::move
Diffstat (limited to 'compat')
-rw-r--r--compat/exception.hpp2
-rw-r--r--compat/format.hpp3
2 files changed, 3 insertions, 2 deletions
diff --git a/compat/exception.hpp b/compat/exception.hpp
index c1315a3c..dd07e483 100644
--- a/compat/exception.hpp
+++ b/compat/exception.hpp
@@ -22,7 +22,7 @@ private:
template<typename Fmt, typename... Ts>
exception::exception(const Fmt& fmt, Ts&&... args) noexcept
{
- fmt::format_to(std::back_inserter(buf), fmt, std::forward<Ts>(args)...);
+ fmt::format_to(std::back_inserter(buf), fmt, Utility::forward<Ts>(args)...);
buf.push_back('\0');
}
diff --git a/compat/format.hpp b/compat/format.hpp
index 6eaf10d8..45f8a9cb 100644
--- a/compat/format.hpp
+++ b/compat/format.hpp
@@ -3,6 +3,7 @@
#include <fmt/compile.h>
#include <Corrade/Containers/StringView.h>
#include <Corrade/Containers/String.h>
+#include <Corrade/Utility/Move.h>
namespace fmt {
@@ -50,7 +51,7 @@ template<size_t N, typename Fmt, typename... Xs>
size_t snformat(char(&buf)[N], Fmt&& fmt, Xs&&... args)
{
constexpr size_t n = N > 0 ? N - 1 : 0;
- auto result = fmt::format_to_n(buf, n, std::forward<Fmt>(fmt), std::forward<Xs>(args)...);
+ auto result = fmt::format_to_n(buf, n, Utility::forward<Fmt>(fmt), std::forward<Xs>(args)...);
const auto len = std::min(n, result.size);
if constexpr(N > 0)
buf[len] = '\0';