summaryrefslogtreecommitdiff
path: root/src/shared/util.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/shared/util.cpp')
-rw-r--r--src/shared/util.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/shared/util.cpp b/src/shared/util.cpp
index aa4ad4b3..74e386a3 100644
--- a/src/shared/util.cpp
+++ b/src/shared/util.cpp
@@ -130,6 +130,13 @@ std::wstring ToLowerCopy(const std::wstring& text)
return result;
}
+std::wstring ToLowerCopy(std::wstring_view text)
+{
+ std::wstring result(text.begin(), text.end());
+ ToLowerInPlace(result);
+ return result;
+}
+
bool CaseInsenstiveComparePred(wchar_t lhs, wchar_t rhs)
{
return std::tolower(lhs, loc) == std::tolower(rhs, loc);