1. Improved Type Declarations: PHP 7.2 introduces new type declarations for function parameters and return values. This allows developers to specify the type of data that a function should accept and return.
2. Object Type Hinting: PHP 7.2 adds support for object type hinting. This allows developers to specify the type of object that a function should accept as a parameter.
3. Argon2 Password Hash Algorithm: PHP 7.2 adds support for the Argon2 password hashing algorithm. This algorithm is considered to be more secure than the previous algorithms used for password hashing.
4. Improved Security: PHP 7.2 includes a number of security improvements, such as the removal of the “unsafe” functions and the addition of the Sodium cryptography library.
5. Improved Performance: PHP 7.2 includes a number of performance improvements, such as the addition of the Zend OPcache and the removal of the old MySQL extension.
6. Deprecation of PHP 4 Style Constructors: PHP 7.2 deprecates the use of PHP 4 style constructors. This means that developers should use the new object-oriented syntax for creating objects.
What’s New in PHP 7.2 (Now Available)