aboutsummaryrefslogtreecommitdiff
path: root/include/cru/base/StringUtil.h
diff options
context:
space:
mode:
authorYuqian Yang <crupest@crupest.life>2025-10-17 22:57:30 +0800
committerYuqian Yang <crupest@crupest.life>2025-10-17 22:57:30 +0800
commitca9334f53b9456a517f8fa4a687e2d2a6cc1ca86 (patch)
treea49651d6af538f90f4033e1ff6361d309ed3fed9 /include/cru/base/StringUtil.h
parent728d592f4075ae78b67dab6911ada05875a470a3 (diff)
downloadcru-ca9334f53b9456a517f8fa4a687e2d2a6cc1ca86.tar.gz
cru-ca9334f53b9456a517f8fa4a687e2d2a6cc1ca86.tar.bz2
cru-ca9334f53b9456a517f8fa4a687e2d2a6cc1ca86.zip
Fix windows build.
Diffstat (limited to 'include/cru/base/StringUtil.h')
-rw-r--r--include/cru/base/StringUtil.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/cru/base/StringUtil.h b/include/cru/base/StringUtil.h
index 8c7841d7..a69bb884 100644
--- a/include/cru/base/StringUtil.h
+++ b/include/cru/base/StringUtil.h
@@ -380,4 +380,9 @@ Index Utf8IndexCodeUnitToCodePoint(const Utf8CodeUnit* ptr, Index size, Index po
Index Utf8IndexCodePointToCodeUnit(const Utf8CodeUnit* ptr, Index size, Index position);
Index Utf16IndexCodeUnitToCodePoint(const Utf16CodeUnit* ptr, Index size, Index position);
Index Utf16IndexCodePointToCodeUnit(const Utf16CodeUnit* ptr, Index size, Index position);
+
+#ifdef _WIN32
+std::wstring ToUtf16(std::string_view str);
+std::string ToUtf8(std::wstring_view str);
+#endif
} // namespace cru::string