On 05/02/2007 02:13 PM, Werner Beroux wrote:
I found an interesting note that I quote here:
"[4] [...] be sure to remember that PHP holds the length property of each
string, and that it shouldn't be calculated with strlen()."
--
http://cvs.php.net/viewvc.cgi/php-src/CODING_STANDARDS?view=co
Now I found nowhere anything else about this and strlen is described
everywhere.
See http://www.php.net/manual/en/zend.variables.php
String length is stored next to the string itself in zval struct.
Is it some kind of new feature of PHP6?
No, this is how it works for ages.
--
Wbr,
Antony Dovgal