aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/UniConversion.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/UniConversion.h')
-rw-r--r--src/UniConversion.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/UniConversion.h b/src/UniConversion.h
index 4cdfe1fac..1b84b8f81 100644
--- a/src/UniConversion.h
+++ b/src/UniConversion.h
@@ -14,12 +14,12 @@ const int UTF8MaxBytes = 4;
const int unicodeReplacementChar = 0xFFFD;
-size_t UTF8Length(const wchar_t *uptr, size_t tlen);
-void UTF8FromUTF16(const wchar_t *uptr, size_t tlen, char *putf, size_t len);
+size_t UTF8Length(std::wstring_view wsv);
+void UTF8FromUTF16(std::wstring_view wsv, char *putf, size_t len);
void UTF8FromUTF32Character(int uch, char *putf);
-size_t UTF16Length(const char *s, size_t len);
-size_t UTF16FromUTF8(const char *s, size_t len, wchar_t *tbuf, size_t tlen);
-size_t UTF32FromUTF8(const char *s, size_t len, unsigned int *tbuf, size_t tlen);
+size_t UTF16Length(std::string_view sv);
+size_t UTF16FromUTF8(std::string_view sv, wchar_t *tbuf, size_t tlen);
+size_t UTF32FromUTF8(std::string_view sv, unsigned int *tbuf, size_t tlen);
unsigned int UTF16FromUTF32Character(unsigned int val, wchar_t *tbuf) noexcept;
std::string FixInvalidUTF8(const std::string &text);