I’ve been running the PHP5.4 RC builds for the last few months, and there are some interesting changes in the upcoming PHP release. On top of all the great new features coming in PHP5.4. After updating to PHP5.4-RC4, a few things that used to not trigger errors and silently do the wrong thing, now trigger notices or warnings.
The sample script above shows the two most recent errors I ran into. I found both tthese errors running the CakePHP testsuite. Interestingly enough the same tests didn’t trigger errors in PHP 5.3 or previous releases of PHP 5.4. Its nice to see things that used to do the ‘wrong thing’ now signalling that behavior. Also good things to keep in mind when upgrading to PHP 5.4.