Other ChangesCore changesCore
In case of a hard OOM (out of memory) condition, PHP
now calls
The Changes in SAPI ModulesCLI
The built-in development
server now accepts requests using the HTTP
The built-in development
server no longer reflects the Changed FunctionsCore
header_register_callback now declares
true as its return type.
It has not been able to return
register_tick_function now declares
true as its return type.
It has always returned
ini_get_all now includes a
fclose, file_put_contents and
copy now return
stream_select,
stream_copy_to_stream,
stream_socket_pair and
stream_is_local now have an additional optional
stream_context_set_default now throws a
ValueError if
DateThe following methods now have tentative static return types:
Filter
The return type of filter_var_array has been
narrowed from
arrayfalsenull
to arrayfalse.
The function always establishes an array before filtering, so LDAP
The return type of ldap_free_result has been
narrowed from bool to true.
The function already always returned MySQLi
The return structure of mysqli_get_charset no longer
contains the undocumented OpenSSL
The output of openssl_x509_parse now contains a
openssl_sign and openssl_verify
now have an additional optional PDO_DBLIBWhen using persistent connections, there is now a liveness check in PDO::__construct. PharPhar::mungServer now supports reference values. Readline
readline_completion_function now declares
true as its return type.
It has always returned Reflection
The outputs of
ReflectionClassConstant::__toString and
ReflectionConstant::__toString now print
bool constant values as Sockets
socket_addrinfo_lookup now has an additional
optional
The return type of socket_cmsg_space has been
narrowed from intnull
to int.
Every failure path has thrown a
ValueError since PHP 8.0.0, so Zip
The return type of zip_entry_close has been narrowed
from bool to true.
The function already always returned Other Changes to ExtensionsFileinfoUpgraded to file 5.48. Custom compiled magic databases from older file versions must be regenerated. HashThe bundled version of xxHash was upgraded to 0.8.2. MySQLi
Added the new constant OpcacheJIT is now supported for ZTS builds on Apple Silicon. Changes to INI File HandlingCoreThe error_include_args INI option has been added to make the display of function arguments consistent in errors; it is off by default. Previously, whether a function showed a parameter in the error was up to each call to the internal error function. Now, all parameters as they were actually passed to the function will be displayed. This uses the same infrastructure as stack traces, so sensitive parameters will not be displayed, and strings will be truncated according to zend.exception_string_param_max_len. MBString
The mbstring.detect_order
INI directive now updates the internal detection order when changed at
runtime via ini_set.
Previously, runtime changes using ini_set did not
take effect for mb_detect_order.
Setting the directive to MySQLi
mysqli.default_port now
checks the validity of the value, which should be between
Opcache
opcache.jit_debug accepts a
new flag: PerformanceCore
printf using only
Arguments are now passed more efficiently to known constructors (e.g.
when using array_map using a first-class callable or partial function application callback will be compiled into the equivalent foreach loop, avoiding the creation of intermediate Closures, the overhead of calling userland callbacks from internal functions and providing for better insight for the JIT. The performance of the TAILCALL VM has been improved, and it is now enabled on Windows when compiling with Clang 19 or later on x86_64. The performance of ZTS builds has been improved. Added a stateless closure cache. Deeply recursive code that causes the VM to allocate new stack pages should now be faster. Improved performance of sorting single-element arrays. Improved performance of the following functions:
DOMMade DOMText::splitText and Dom\Text::splitText faster and consume less memory. GDimagebmp, imagewbmp, imagegd, and imagegd2 now buffer output when writing to PHP streams, significantly improving performance when writing images to files. Improved performance of imagegrabscreen and imagegrabwindow on Windows. IntlImproved performance of IntlCalendar::getAvailableLocales and IntlDateFormatter::localtime/datefmt_localtime by pre-allocating their returned arrays. Improved performance of transliterator_list_ids and resourcebundle_locales by pre-allocating their returned arrays. Optimized callback invocation in IntlChar::enumCharTypes. JSONImproved performance of encoding arrays and objects.
Improved performance of indentation generation in
json_encode when using
MBStringImproved performance of mb_str_pad. PharReduced temporary allocations when iterating Phar directories. URIImproved performance of Uri\WhatWg\Url::parse when collecting validation errors by pre-allocating the error array. Reduced allocations when reading IPv6/IPvFuture hosts and paths with Uri\Rfc3986\Uri. Improved performance and memory consumption when using normalizing (non-raw) getters on already-normalized URIs with Uri\Rfc3986\Uri. ZipImproved performance of ZipArchive::addGlob and ZipArchive::addPattern by pre-allocating their returned arrays. Avoid string copies in ZipArchive::addFromString. |