Backward Incompatible ChangesPHP CorePrograms that were very close to overflowing the call stackPrograms that were very close to overflowing the call stack may now throw an Error when using more than zend.max_allowed_stack_size-zend.reserved_stack_size bytes of stack (fiber.stack_size-zend.reserved_stack_size for fibers). Executing proc_get_status() multiple times
Executing proc_get_status multiple times will now always
return the right value on POSIX systems. Previously, only the first call
of the function returned the right value. Executing
proc_close after proc_get_status
will now also return the right exit code. Previously this would return
Zend Max Execution TimersZend Max Execution Timers is now enabled by default for ZTS builds on Linux. Uses of traits with static propertiesUses of traits with static properties will now redeclare static properties inherited from the parent class. This will create a separate static property storage for the current class. This is analogous to adding the static property to the class directly without traits. Assigning a negative index to an empty array
Assigning a negative index $n to an empty array will now make sure that the
next index is Class constant visibility variance checkClass constant visibility variance is now correctly checked when inherited from interfaces. WeakMap entries whose key maps to itselfWeakMap entries whose key maps to itself (possibly transitively) may now be removed during cycle collection if the key is not reachable except by iterating over the WeakMap (reachability via iteration is considered weak). Previously, such entries would never be automatically removed. DateThe DateTime extension has introduced Date extension specific exceptions and errors under the DateError and DateException hierarchies, instead of warnings and generic exceptions. This improves error handling, at the expense of having to check for errors and exceptions. DOMCalling DOMChildNode::after, DOMChildNode::before, DOMChildNode::replaceWith on a node that has no parent is now a no-op instead of a hierarchy exception, which is the behaviour demanded by the DOM specification.
Using the DOMParentNode
and DOMChildNode methods without a document now
works instead of throwing a Calling DOMDocument::createAttributeNS without specifying a prefix would incorrectly create a default namespace, placing the element inside the namespace instead of the attribute. This bug is now fixed.
DOMDocument::createAttributeNS would previously
incorrectly throw a New methods and properties were added to some DOM classes. If a userland class inherits from these classes and declare a method or property with the same name, the declarations must be compatible. Otherwise, a typical compile error about incompatible declarations will be thrown. See the list of new features and new functions for a list of the newly implemented methods and properties. FFI
C functions that have a return type of void now return OpcacheThe opcache.consistency_checks INI directive was removed. This feature was broken with the tracing JIT, as well as with inheritance cache, and has been disabled without a way to enable it since PHP 8.1.18 and PHP 8.2.5. Both the tracing JIT and inheritance cache may modify shm after the script has been persisted by invalidating its checksum. The attempted fix skipped over the modifiable pointers but was rejected due to complexity. For this reason, it was decided to remove the feature instead. PharThe type of Phar class constants are now declared. StandardThe range function has had various changes:
number_format now handles negative
The file flags error check now catches all invalid flags.
Notably SNMPThe type of SNMP class constants are now declared. |