From a60cebd0f933ba5b2d8eff419ba340e9261bdc55 Mon Sep 17 00:00:00 2001 From: Project579 Date: Sat, 10 Sep 2022 12:11:56 +0200 Subject: [PATCH] Use std::u8string_view in debug logger overloads parameters. --- components/debug/debuglog.cpp | 2 +- components/debug/debuglog.hpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/components/debug/debuglog.cpp b/components/debug/debuglog.cpp index bb67847f6e..255b0d5fc9 100644 --- a/components/debug/debuglog.cpp +++ b/components/debug/debuglog.cpp @@ -63,7 +63,7 @@ Log& Log::operator<<(std::u8string&& rhs) return *this; } -Log& Log::operator<<(const std::u8string& rhs) +Log& Log::operator<<(const std::u8string_view rhs) { if (mShouldLog) std::cout << Misc::StringUtils::u8StringToString(rhs); diff --git a/components/debug/debuglog.hpp b/components/debug/debuglog.hpp index 526763d9f6..f57ae96d12 100644 --- a/components/debug/debuglog.hpp +++ b/components/debug/debuglog.hpp @@ -43,7 +43,7 @@ public: Log& operator<<(std::u8string&& rhs); - Log& operator<<(const std::u8string& rhs); + Log& operator<<(std::u8string_view rhs); Log& operator<<(const char8_t* rhs);