We’re happy to share some great news.
We have added support for PHP 8.1 on our shared hosting servers.
Key changes in PHP 8.1:
– Added support for Enums — collections of constant values.
– Added the ability to mark class properties as read-only — data in such properties can only be written once.
– Added support for Fibers (lightweight threads) — allowing blocks of code to be allocated that can be suspended and resumed, similar to generators.
– Added support for Intersection Types — allows creating new types whose values must match several types at once.
– A new “never” return type — allows informing static analyzers that program execution is halted.
– New Callable syntax — closures can now be formed by calling a function and passing it an argument with the value “…”.
– The “final” keyword can now be used to prevent overriding parent class constants.
– New fsync and fdatasync functions — for forcing changes from the disk cache to be saved.
– A new array_is_list function — lets you determine whether array keys are in increasing order starting from 0.
– Added support for “0o” and “0O” prefixes for octal numbers.
– Improved performance.
