3 ms·
The Windows API uses WCHAR = wchar_t, so if you use char16_t, you have to convert back and forth to avoid running afoul of strict aliasing rules. This imposes c
by ack_complete 6mo ago
The Windows API uses WCHAR = wchar_t, so if you use char16_t, you have to convert back and forth to avoid running afoul of strict aliasing rules. This imposes conversion costs without benefits; both using wchar_t directly or converting to/from UTF-8 are better.
- delta_p_delta_x 6mo agoOr, set up the manifest in your app[1], and just use UTF-8 and `std::string`/`std::string_view` everywhere. [1]: https://learn.microsoft.com/en-gb/windows/apps/design/globalizing/use-utf8-code-page https://learn.microsoft.com/en-gb/windows/apps/design/global...