Re: What "Unicode support" really means
| From: | Andrea Faulds | Date: | Wed, 05 Mar 2014 21:10:55 +0000 |
| Subject: | Re: What "Unicode support" really means | ||
| References: | 1 2 3 4 5 6 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-72941@lists.php.net to get a copy of this message | ||
On 5 Mar 2014, at 21:07, Derick Rethans <derick@php.net> wrote:
> Well, even with UTF-32 (4 bytes for every character) it is not so easy
> to calculate the number of "characters". Characters can also be combined
> from multiple Unicode Codepoints, so even Å (U+00C5 LATIN CAPITAL LETTER
> A WITH RING ABOVE) can also be a combination of U+0041 LATIN CAPITAL
> LETTER A + U+030A COMBINING RING ABOVE. So things like substr, and
> wordwrap would have to deal with that too, making the "performance
> benefits" of UTF-32 largely go away.
Are we sure we want substr() to operate on printed characters and not codepoints?
--
Andrea Faulds
http://ajf.me/