▲ | 77pt77 14 hours ago | |||||||
> If you treat your strings as opaque blobs, and use UTF8, most of internationalization problems go away This is laughably naive. So many things can go wrong. Strings are not arrays of bytes. There is a price to pay if someone doesn't understand that or chooses to ignore it. | ||||||||
▲ | shakna 9 hours ago | parent | next [-] | |||||||
> Strings are not arrays of bytes. That very much depends on the language that you are using. In some, they are. | ||||||||
▲ | hughesjj 14 hours ago | parent | prev | next [-] | |||||||
RTL go brrr | ||||||||
| ||||||||
▲ | lelandbatey 10 hours ago | parent | prev [-] | |||||||
And yet when stored on any computer system, that string will be encoded using some number of bytes. Which you can set a limit on even though you cannot cut, delimit, or make any other inference about that string from the bytes without doing some kind of interpretation. But the bytes limit is enough for the situation the OP is talking about. |