[core] nits

Signed-off-by: x7z4w <x7z4w@noreply.codeberg.org>
This commit is contained in:
x7z4w
2025-08-21 13:56:48 +00:00
committed by Konstantin Pastbin
parent 3f7815017e
commit 3c34765595
5 changed files with 19 additions and 11 deletions

View File

@@ -213,7 +213,7 @@ void ReorderRTL(TextSegments & segments)
TextSegments GetTextSegments(std::string_view utf8)
{
ASSERT(!utf8.empty(), ("Shaping of empty strings is not supported"));
ASSERT(std::string::npos == utf8.find_first_of("\r\n"), ("Shaping with line breaks is not supported", utf8));
ASSERT(std::string::npos == utf8.find_first_of("\n"), ("Shaping with line breaks is not supported", utf8));
// TODO(AB): Can unnecessary conversion/allocation be avoided?
TextSegments segments{strings::ToUtf16(utf8), {}};