Re: Re: Regarding the latest patch on fgetcsv() (stable branch)
| From: | Rasmus Lerdorf | Date: | Sat, 13 Dec 2003 02:12:27 +0000 |
| Subject: | Re: Re: Regarding the latest patch on fgetcsv() (stable branch) | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-6402@lists.php.net to get a copy of this message | ||
On Sat, 13 Dec 2003, Moriyoshi Koizumi wrote:
> Overloading is evil, because functions like substr() are often
> used to splice a certain length of octets byte-wise while mb_substr()
> treats the sequence of octets on a character-basis.
I don't know about this happening often. In singlebyte apps I don't see
this happening often. People splice on character boundaries. Perhaps in
multibyte apps people are using substr this way, but that would seem to be
an incorrect usage of the function. People who do this are taking
advantage of a side-effect of a function designed for a different
character set. substr as documented works on characters, not octets.
-Rasmus