//
// fmt::internal::UTF16ToUTF8::UTF16ToUTF8 from 0x1800171b0 to 0x180017208 (88 bytes)
//
// 2 xrefs:
// > ??> @ 0x18014cf68
// > ??> @ 0x1801b8704
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:21:25 +0000
//
size_t *__fastcall fmt::internal::UTF16ToUTF8::UTF16ToUTF8(size_t *a1, size_t *a2)
{
size_t v2; // r8
size_t *v4; // rcx
v2 = *a2;
*a1 = *a2;
a1[1] = a2[1];
v4 = (size_t *)a2[2];
if ( v4 == a2 + 3 )
{
a1[2] = (size_t)(a1 + 3);
memmove(a1 + 3, a2 + 3, v2);
}
else
{
a1[2] = (size_t)v4;
a2[2] = (size_t)(a2 + 3);
}
return a1;
}