> On Feb 5, 2017, at 2:57 PM, Ted F.A. van Gaalen <[email protected]> wrote:
> 
> However, that is not the case with UTF-32, because with UTF-32 encoding
> each character has a fixed-width and always occupies exactly 4 bytes, 32 bit. 
> Ergo: the problem can be easily solved: The simple solution is to always 
> and without exception use UTF-32 encoding as Swift's internal 
> string format because it only contains fixed width Unicode characters. 

Those are not (user-perceived) Characters; they are Unicode Scalar Values 
(often called "characters" by the Unicode standard.  Characters as defined in 
Swift (a.k.a. extended grapheme clusters) have no fixed-width encoding, and 
Unicode scalar values are an inappropriate unit for most string processing. 
Please read the manifesto for details.

Sent from my iPad
_______________________________________________
swift-evolution mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to