Skip to content

Commit 8cce1c4

Browse files
wip
Signed-off-by: Christian Parpart <[email protected]>
1 parent d05a2db commit 8cce1c4

7 files changed

+829
-245
lines changed

src/libunicode/capi.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ int u32_gc_width(u32_char_t const* codepoints, size_t size, int mode)
4949
while (segmenter.codepointsAvailable())
5050
{
5151
auto const cluster = *segmenter;
52-
int thisWidth = unicode::width(cluster.front());
52+
int thisWidth = static_cast<int>(unicode::width(cluster.front()));
5353
if (mode != GC_WIDTH_MODE_NON_MODIFIABLE)
5454
{
5555
for (size_t i = 1; i < size; ++i)
@@ -60,7 +60,7 @@ int u32_gc_width(u32_char_t const* codepoints, size_t size, int mode)
6060
{
6161
case 0xFE0E: return 1;
6262
case 0xFE0F: return 2;
63-
default: return unicode::width(codepoint);
63+
default: return static_cast<int>(unicode::width(codepoint));
6464
}
6565
}();
6666
if (width && width != thisWidth)

0 commit comments

Comments
 (0)