PHP 7 awesome features
PHP 7 has been released. The 7.0.0 major release contains so many amazing features. PHP 6 was skipped because most of the new features were added to PHP 5.6 .
Some of my favourite features on version 7 are listed below. I will update this list as I keep trying them out. Detailed descriptions of features will be in my next post.
New Zend Engine
PHP7 comes with a new engine codenamed PHP#NG (Next Generation)
PHPNG engine comes with significant performance improvement. The dev team of PHPNG refactored the Zend Engine, and optimized memory usage.
Custom Error Handling
The new Engine Exceptions allows you to replace fatal errors with exceptions. If the exception is not caught, PHP will continue to return the same fatal errors as it previous versions.
Spaceship and Null Coalescing Operators
The Spaceship operator runs under the official name of Combined Comparison Operator. The new operator looks like this: <=>
The Null Coalescing operator is denoted with two question marks ( ?? )
Deprecated functionalities removed
The goal of PHP 7 was to free up the space to enable improvement, so it was good to remove many deprecated functionalities , old and unsupported Server APIs and extensions. If you want to check which are these in detail, click here and here.