diff options
| author | isanae <14251494+isanae@users.noreply.github.com> | 2020-02-10 10:51:23 -0500 |
|---|---|---|
| committer | isanae <14251494+isanae@users.noreply.github.com> | 2020-02-18 17:23:48 -0500 |
| commit | 3a65665d36022c50637fc53d5c9c1ee022c5b3b5 (patch) | |
| tree | 655dbb9d4c8d72b88b3fac94deceb350513aa780 /src/shared/util.cpp | |
| parent | 3db95eb4043b8da20e99dd7476bc82468a4609fb (diff) | |
wstring_view when possible
first implementation of NtQueryDirectoryFile
Diffstat (limited to 'src/shared/util.cpp')
| -rw-r--r-- | src/shared/util.cpp | 7 |
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);
|
