On 11/14/2006 11:24 AM, Richard Quadling wrote:
As we are often told on this list, PHP is not C.

It seems utterly ridiculous to return maxlen-1.

It also might seem ridiculous to have strlen() and str_replace(), but there are 
good reasons to have strlen() instead of str_len().

Whilst this is sure as hell a BC, it should work "properly". If I ask
for 10, I want 10. I wouldn't have asked for 10 otherwise. Having to
know the "magic" to get things to work is plainly bad magic.

In terms of KISS, 10 means 10.

In terms of KISS BC means "backward compatibility". If you don't want BC - release your own PHP.

Unless PHP !== KISS therefore 10 === 9.

Make the break. Deal with it. It was wrong and now it is fixed.

"It works this way since PHP3" means "it works right" even if there was a bug 
in PHP3.
That's because thousands of people could rely on this behaviour (which is, I repeat, very well documented and pretty much expected).

--
Wbr, Antony Dovgal

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to