3 ms·
The real problem is that Go does not actually have a string type. It only has byte strings which can accidentally also be text strings encoded in utf-8. This i
by user-the-name 6y ago
The real problem is that Go does not actually have a string type. It only has byte strings which can accidentally also be text strings encoded in utf-8.
This is a very, very sloppy way to handle text, and will inevitably lead to a huge number of mistakes and broken software.
Any well-designed modern language really should make a strong separation between raw byte buffers and text strings. They are very different things, and one can definitely not trivially be converted to the other.
- naniwaduni 6y agoThe fact is that there is no correct "text string" type, because there are no valid operations on so-called text strings in general.
- user-the-name 6y agoThat... makes no sense? Of course there are a lot of valid operations on text strings?