On Wednesday, 18 July 2018 at 12:03:02 UTC, Eugene Wissner wrote:
Therefore it shouldn't compile at all, but

rcstring("ä")[].split("|")

or

rcstring("ä").byCodePoint.split("|")

+1 to requiring an explicit byCodeUnit or whatever.

For every "obvious" way to interpret a string as a range, you can find an application where the obvious code is surprisingly buggy.

(BTW, rcstring("ä").byCodePoint.split("|") is buggy for characters made of multiple codepoints. Canonicalisation doesn't fix it because many characters just don't have a single-codepoint form.)

Reply via email to