Re:Show HN: C3 – A C alternative that looks like C
by 95014_refugee on Tuesday July 20, 2021 @04:55AM
(#27891411)
Utf-8 is instant failure for embedded targets, and essentially guarantees the failure of any C replacement.
[ Parent
| on HN ]
Re:Show HN: C3 – A C alternative that looks like C
by flohofwoe on Tuesday July 20, 2021 @05:19AM
(#27891559)
Huh? Please explain if you don't mind. UTF-8 is completely backward compatible with 7-bit ASCII, so if you don't need international characters everything remains exactly the same, and if you need international characters, strings are still just regular "bags of bytes". The only difference (for international strings) is that the number of bytes in the strings isn't the same as the number of characters (or rather UNICODE code points). But that's only relevant if you actually need to process a string down on the character level. Most CRT ASCII string functions work just fine on UTF-8 data, even strtok() if the delimiters are 7-bit ASCII.