Just-In-Time (JIT) Compilation in PHP 8.0

Just-In-Time (JIT) Compilation in PHP 8.0

Just-in-time (JIT) compilation is a process that takes compilation of the code at run time. JIT compilation allows to improve performance of interpreted programming languages. Since PHP 8.0, we can…
Using Attributes in PHP 8.0

Using Attributes in PHP 8.0

PHP allows to specify doc comments on declarations in code which can be retrieved using the Reflection API. However, doc comments are just strings that provides unstructured metadata information. There…
Constructor Property Promotion in PHP 8.0

Constructor Property Promotion in PHP 8.0

Properties are class member variables that stores values like strings, integers, booleans, etc. We can set properties via class constructor, setter method or directly if property is public. When we…
Using WeakMap in PHP 8.0

Using WeakMap in PHP 8.0

The SplObjectStorage class allows to store additional data about objects. Objects are stored as keys and associated data as values. In other words, this class allows to create a map…
Using Nullsafe Operator in PHP 8.0

Using Nullsafe Operator in PHP 8.0

Null is a type that has only one possible value null. The null value indicates that variable doesn't have a value. However, due null value we might need to write…