From 7d2f6bd5280613538c4beafac26a39348992d103 Mon Sep 17 00:00:00 2001 From: Neil Date: Sat, 13 Aug 2022 18:12:55 +1000 Subject: Reduce warnings with noexcept, fewer casts, and other minor changes. --- src/UniConversion.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/UniConversion.cxx') diff --git a/src/UniConversion.cxx b/src/UniConversion.cxx index 91aea6cde..3f3bc5904 100644 --- a/src/UniConversion.cxx +++ b/src/UniConversion.cxx @@ -358,8 +358,8 @@ int UTF8Classify(const unsigned char *us, size_t len) noexcept { return UTF8MaskInvalid | 1; } -int UTF8DrawBytes(const unsigned char *us, int len) noexcept { - const int utf8StatusNext = UTF8Classify(us, len); +int UTF8DrawBytes(const char *s, size_t len) noexcept { + const int utf8StatusNext = UTF8Classify(reinterpret_cast(s), len); return (utf8StatusNext & UTF8MaskInvalid) ? 1 : (utf8StatusNext & UTF8MaskWidth); } -- cgit v1.2.3