Biohazrd icon indicating copy to clipboard operation
Biohazrd copied to clipboard

Add support for `char32_t` and `wchar_t` on Itanium platforms

Open PathogenDavid opened this issue 3 years ago • 1 comments

char32_t represents UTF-32 codepoints. They aren't supported yet purely out of lack of need and unclear best translation.

How these might translate to C# is somewhat unclear. Older methods such as Char.ConvertFromUtf32 use int for UTF32 codepoints.

In theory System.Text.Rune might be a good choice here, but it doesn't allow surrogates. I'm unsure if there's a legitimate reason for codepoints from the surrogate range to appear in UTF-32. However, we would be allows C++ to make invalid runes since the Rune constructor protects against surrogates.

More research needs to be done to determine if a reasonable ideal default translation can be supported in Biohazrd. Until then it most likely makes more sense for people to provide their own purpose-built translation. (If you make one, please comment on how you did it and how it worked out for you!)

PathogenDavid avatar Sep 13 '20 01:09 PathogenDavid

This also applies to wchar_t on Itanium (IE: Linux)

PathogenDavid avatar Aug 04 '21 20:08 PathogenDavid