Merge PHP 5.4 changes

:+1:  closes #4