2023-08-30 03:25:46 +08:00
|
|
|
PHP 8.4 UPGRADE NOTES
|
2012-03-06 04:14:04 +08:00
|
|
|
|
|
|
|
1. Backward Incompatible Changes
|
|
|
|
2. New Features
|
2014-05-01 18:27:38 +08:00
|
|
|
3. Changes in SAPI modules
|
|
|
|
4. Deprecated Functionality
|
|
|
|
5. Changed Functions
|
|
|
|
6. New Functions
|
|
|
|
7. New Classes and Interfaces
|
2015-02-10 15:56:18 +08:00
|
|
|
8. Removed Extensions and SAPIs
|
2014-05-01 18:27:38 +08:00
|
|
|
9. Other Changes to Extensions
|
|
|
|
10. New Global Constants
|
|
|
|
11. Changes to INI File Handling
|
2014-08-22 19:35:07 +08:00
|
|
|
12. Windows Support
|
2019-01-28 17:34:31 +08:00
|
|
|
13. Other Changes
|
|
|
|
14. Performance Improvements
|
2010-03-25 00:23:50 +08:00
|
|
|
|
|
|
|
========================================
|
2012-03-06 04:14:04 +08:00
|
|
|
1. Backward Incompatible Changes
|
2010-03-25 00:23:50 +08:00
|
|
|
========================================
|
2016-04-25 05:49:52 +08:00
|
|
|
|
2023-12-21 22:09:27 +08:00
|
|
|
- CLI:
|
|
|
|
. The builtin server looks for an index file recursively by traversing parent
|
|
|
|
directories in case the specified file cannot be located. This process was
|
|
|
|
previously skipped if the path looked like it was referring to a file, i.e.
|
|
|
|
if the last path component contained a period. In that case, a 404 error was
|
|
|
|
returned. The behavior has been changed to look for an index file in all
|
|
|
|
cases.
|
|
|
|
|
2024-01-07 21:38:26 +08:00
|
|
|
- Core:
|
|
|
|
. The type of PHP_DEBUG and PHP_ZTS constants changed to bool.
|
2024-05-30 01:06:18 +08:00
|
|
|
. The name of uploaded files and files created by the tempnam() function are
|
|
|
|
now 13 bytes longer. Total length is platform-dependent.
|
2024-07-22 21:53:41 +08:00
|
|
|
. Encountering recursion during comparison now results in a Error exception,
|
|
|
|
rather than a fatal error.
|
2024-08-09 17:56:16 +08:00
|
|
|
. Indirect modification of readonly properties within __clone() is no longer
|
|
|
|
allowed, e.g. $ref = &$this->readonly. This was already forbidden for
|
|
|
|
readonly initialization, and was an oversight in the "readonly
|
|
|
|
reinitialization during cloning" implementation.
|
2024-01-07 21:38:26 +08:00
|
|
|
|
2024-08-11 10:24:00 +08:00
|
|
|
- DBA:
|
|
|
|
. dba_open() and dba_popen() will now return a Dba\Connection
|
|
|
|
object rather than a resource. Return value checks using is_resource()
|
|
|
|
should be replaced with checks for `false`.
|
|
|
|
|
2023-09-09 07:14:26 +08:00
|
|
|
- DOM:
|
2024-04-21 05:21:40 +08:00
|
|
|
. Added DOMNode::compareDocumentPosition() and DOMNode::DOCUMENT_POSITION_*
|
|
|
|
constants.
|
|
|
|
If you have a method or constant with the same name, you might encounter errors
|
|
|
|
if the declaration is incompatible.
|
2023-12-05 06:49:25 +08:00
|
|
|
. Some DOM methods previously returned false or a PHP_ERR DOMException if a new
|
|
|
|
node could not be allocated. They consistently throw an INVALID_STATE_ERR
|
|
|
|
DOMException now. This situation is extremely unlikely though and probably
|
|
|
|
will not affect you. As a result DOMImplementation::createDocument() now has
|
|
|
|
a tentative return type of DOMDocument instead of DOMDocument|false.
|
2024-02-23 06:42:17 +08:00
|
|
|
. Previously, DOMXPath objects could be cloned, but resulted in an unusable
|
|
|
|
object. This is no longer possible, and cloning a DOMXPath object now throws
|
|
|
|
an error.
|
2024-08-13 19:39:20 +08:00
|
|
|
. DOMDocument::$actualEncoding, DOMDocument::config, DOMEntity::$actualEncoding,
|
|
|
|
DOMEntity::$encoding, DOMEntity::$version have been deprecated as part of the
|
|
|
|
https://wiki.php.net/rfc/deprecations_php_8_4 RFC.
|
2023-09-09 07:14:26 +08:00
|
|
|
|
2024-07-28 20:03:26 +08:00
|
|
|
- GMP:
|
|
|
|
. The GMP class is now final and cannot be extended anymore.
|
|
|
|
RFC: https://wiki.php.net/rfc/gmp-final
|
2024-07-30 23:41:49 +08:00
|
|
|
. Casting a GMP object to bool changed so that 0 becomes false and everything else
|
|
|
|
becomes true.
|
|
|
|
RFC: https://wiki.php.net/rfc/fix_up_bcmath_number_class
|
2024-07-28 20:03:26 +08:00
|
|
|
|
2024-02-27 01:03:17 +08:00
|
|
|
- Intl:
|
|
|
|
. resourcebundle_get(), ResourceBundle::get(), and accessing offsets on a
|
|
|
|
ResourceBundle object now throw:
|
|
|
|
- TypeError for invalid offset types
|
|
|
|
- ValueError for an empty string
|
|
|
|
- ValueError if the integer index does not fit in a signed 32 bit integer
|
|
|
|
|
2023-12-07 07:47:00 +08:00
|
|
|
- MBString:
|
|
|
|
. mb_encode_numericentity() and mb_decode_numericentity() now check that
|
|
|
|
the $map is only composed of integers, if not a ValueError is thrown.
|
2023-12-08 01:23:01 +08:00
|
|
|
. mb_http_input() now always throws a ValueError if the $type is invalid.
|
2024-04-24 06:48:02 +08:00
|
|
|
. mb_http_output() now checks that the $encoding parameter does not
|
|
|
|
contain any null bytes. If it does, a ValueError is now thrown.
|
2023-12-10 21:02:26 +08:00
|
|
|
. On invalid strings (those with encoding errors), mb_substr() now interprets
|
|
|
|
character indices in the same manner as most other mbstring functions. This
|
|
|
|
means that character indices returned by mb_strpos() can be passed to mb_substr().
|
|
|
|
. For SJIS-Mac (MacJapanese) strings, character indices passed to mb_substr() now
|
|
|
|
refer to the indices of the Unicode codepoints which are produced when the string
|
|
|
|
is converted to Unicode. This is significant because around 40 SJIS-Mac characters
|
|
|
|
convert to a sequence of multiple Unicode codepoints.
|
2023-12-07 07:47:00 +08:00
|
|
|
|
Make ext/odbc default value handling more consistent (#13910)
These changes are carved off from https://github.com/php/php-src/pull/12040/files. I noticed that there are some inconsistencies between odbc_fetch_object()/odbc_fetch_array(), odbc_fetch_into(), as well as odbc_fetch_row(), specifically in how they handle the $row parameter. Now, I tried to align their behaviour the following way:
- I made null the default value. Previously, the default values were one of the following: -1, -1, 0, and null, respectively.
- odbc_fetch_row() has been returning false indicating there is no more rows when 0 is passed as $row. Now, a warning is also emitted in this case, because the null default value is not new, because it's available since PHP 8.0.
- When HAVE_SQL_EXTENDED_FETCH is not defined, the $row parameter is always ignored. Previously, some of the functions didn't accept it at all. Now a warning is emitted if the feature is not supported, but the parameter has any meaningful value (is greater than or equal to 1).
2024-04-11 04:49:41 +08:00
|
|
|
- ODBC:
|
|
|
|
. odbc_fetch_row() returns false when a value less than or equal to 0 is
|
|
|
|
passed for parameter $row. Now, a warning is emitted in this case.
|
2024-04-28 21:45:56 +08:00
|
|
|
. odbc_connect() and odbc_pconnect() will now return an Odbc\Connection
|
|
|
|
object rather than a resource. Return value checks using is_resource()
|
|
|
|
should be replaced with checks for `false`.
|
|
|
|
. odbc_prepare(), odbc_exec(), and various other functions will now return
|
|
|
|
an Odbc\Result object rather than a resource. Return value checks using
|
|
|
|
is_resource() should be replaced with checks for `false`.
|
Make ext/odbc default value handling more consistent (#13910)
These changes are carved off from https://github.com/php/php-src/pull/12040/files. I noticed that there are some inconsistencies between odbc_fetch_object()/odbc_fetch_array(), odbc_fetch_into(), as well as odbc_fetch_row(), specifically in how they handle the $row parameter. Now, I tried to align their behaviour the following way:
- I made null the default value. Previously, the default values were one of the following: -1, -1, 0, and null, respectively.
- odbc_fetch_row() has been returning false indicating there is no more rows when 0 is passed as $row. Now, a warning is also emitted in this case, because the null default value is not new, because it's available since PHP 8.0.
- When HAVE_SQL_EXTENDED_FETCH is not defined, the $row parameter is always ignored. Previously, some of the functions didn't accept it at all. Now a warning is emitted if the feature is not supported, but the parameter has any meaningful value (is greater than or equal to 1).
2024-04-11 04:49:41 +08:00
|
|
|
|
2023-11-29 03:14:58 +08:00
|
|
|
- Opcache:
|
|
|
|
. The JIT config defaults changed from opcache.jit=tracing and
|
|
|
|
opcache.jit_buffer_size=0 to opcache.jit=disable and
|
|
|
|
opcache.jit_buffer_size=64M, respectively. This does not affect the default
|
|
|
|
behavior, the JIT is still disabled by default. However, it is now disabled
|
|
|
|
through the opcache.jit setting, rather than opcache.jit_buffer_size. This
|
|
|
|
may affect users who previously enabled JIT through opcache.jit_buffer_size
|
|
|
|
exclusively, without also specifying a JIT mode using opcache.jit. To enable
|
|
|
|
JIT, set the opcache.jit config value accordingly.
|
2024-03-19 20:06:29 +08:00
|
|
|
. The maximum value of the opcache.interned_strings_buffer setting on 64bit
|
|
|
|
architectures is now 32767 (it was previously 4095).
|
2024-06-06 02:31:32 +08:00
|
|
|
. If JIT is enabled, PHP will now exit with a fatal error on startup in case
|
|
|
|
of JIT startup initialization issues.
|
2023-11-29 03:14:58 +08:00
|
|
|
|
2024-02-17 21:15:04 +08:00
|
|
|
- PCRE:
|
2024-06-08 19:03:31 +08:00
|
|
|
. The bundled pcre2lib has been updated to version 10.44.
|
2024-02-17 21:15:04 +08:00
|
|
|
As a consequence, this means {,3} is now recognized as a quantifier instead
|
|
|
|
of as text. Furthermore, the meaning of some character classes in UCP mode
|
|
|
|
has changed. Consult https://github.com/PCRE2Project/pcre2/blob/master/NEWS
|
|
|
|
for a full changelog.
|
|
|
|
|
2023-12-05 00:05:30 +08:00
|
|
|
- PDO_DBLIB:
|
|
|
|
. setAttribute, DBLIB_ATTR_STRINGIFY_UNIQUEIDENTIFIER and DBLIB_ATTR_DATETIME_CONVERT
|
|
|
|
have been changed to set value as a bool.
|
|
|
|
|
|
|
|
- PDO_FIREBIRD:
|
2024-08-13 00:59:12 +08:00
|
|
|
. Since some Firebird C++ APIs are used now, this extension requires a C++
|
|
|
|
compiler to be built.
|
2023-12-05 00:05:30 +08:00
|
|
|
. getAttribute, ATTR_AUTOCOMMIT has been changed to get the value as a bool.
|
|
|
|
|
|
|
|
- PDO_MYSQL:
|
|
|
|
. getAttribute, ATTR_AUTOCOMMIT, ATTR_EMULATE_PREPARES, MYSQL_ATTR_DIRECT_QUERY have
|
2024-04-10 09:02:24 +08:00
|
|
|
been changed to get values as bool.
|
2023-12-05 00:05:30 +08:00
|
|
|
|
2023-10-12 09:35:42 +08:00
|
|
|
- PDO_PGSQL:
|
|
|
|
. The DSN's credentials, when set, are given priority over their PDO
|
|
|
|
constructor counterparts, being closer to the documentation states.
|
|
|
|
|
2023-11-16 08:40:18 +08:00
|
|
|
- PCNTL:
|
|
|
|
. The functions pcntl_sigprocmask(), pcntl_sigwaitinfo() and
|
|
|
|
pcntl_sigtimedwait() now throw:
|
|
|
|
- A ValueError if the $signals array is empty (except for
|
|
|
|
pcntl_sigprocmask() if the $mode is SIG_SETMASK).
|
|
|
|
- A TypeError if a value of the $signals array is not an integer
|
|
|
|
- A ValueError if a value of the $signals array is not a valid signal number
|
|
|
|
Moreover, those functions now always return false on failure.
|
|
|
|
In some case previously it could return the value -1.
|
|
|
|
. The function pcntl_sigprocmask() will also now throw:
|
|
|
|
- A ValueError if $mode is not one of SIG_BLOCK, SIG_UNBLOCK, or SIG_SETMASK
|
|
|
|
. The function pcntl_sigtimedwait() will also now throw:
|
|
|
|
- A ValueError if $seconds is less than 0
|
|
|
|
- A ValueError if $nanoseconds is less than 0 or greater than 1e9
|
|
|
|
- A ValueError if both $seconds and $nanoseconds are 0
|
|
|
|
|
2023-10-01 00:00:45 +08:00
|
|
|
- SimpleXML:
|
|
|
|
. Get methods called, or casting to a string on a SimpleXMLElement will no
|
|
|
|
longer implicitly reset the iterator data, unless explicitly rewound.
|
|
|
|
For example, casting an element to a string within a foreach loop would
|
|
|
|
cause an infinite loop because it destroyed the current iterator data.
|
|
|
|
This is no longer the case as a consequence of the bugfixes for GH-12192,
|
|
|
|
GH-12208, #55098.
|
2024-01-19 03:28:01 +08:00
|
|
|
. Calling simplexml_import_dom() with a non-XML object now throws a TypeError
|
|
|
|
instead of a ValueError.
|
2023-08-21 13:14:45 +08:00
|
|
|
|
2024-05-07 15:17:38 +08:00
|
|
|
- SOAP:
|
|
|
|
. SoapClient::$httpurl is now a Soap\Url object rather than a resource.
|
|
|
|
Checks using is_resource() (i.e. is_resource($client->httpurl)) should be
|
|
|
|
replaced with checks for null (i.e. $client->httpurl !== null).
|
2024-05-06 15:08:35 +08:00
|
|
|
. SoapClient::$sdl is now a Soap\Sdl object rather than a resource.
|
|
|
|
Checks using is_resource() (i.e. is_resource($client->sdl)) should be
|
|
|
|
replaced with checks for null (i.e. $client->sdl !== null).
|
2024-05-08 04:57:31 +08:00
|
|
|
. SoapClient::$typemap is now an array rather than a resource.
|
|
|
|
Checks using is_resource() (i.e. is_resource($client->typemap)) should be
|
|
|
|
replaced with checks for null (i.e. $client->typemap !== null).
|
2024-05-30 01:51:49 +08:00
|
|
|
. The SOAP extension gained an optional dependency on the session extension.
|
|
|
|
If you build PHP without the session extension and with --enable-rtld-now,
|
|
|
|
you will experience errors on startup if you also use the SOAP extension.
|
|
|
|
To solve this, either don't use rtld-now or load the session extension.
|
2024-05-06 15:08:35 +08:00
|
|
|
|
2023-10-09 00:57:57 +08:00
|
|
|
- SPL:
|
|
|
|
. Out of bounds accesses in SplFixedArray now throw an exception of type
|
|
|
|
OutOfBoundsException instead of RuntimeException. As OutOfBoundsException
|
|
|
|
is a child class of RuntimeException, code that uses RuntimeException
|
|
|
|
continues to function.
|
|
|
|
|
2023-09-22 23:35:03 +08:00
|
|
|
- Standard:
|
|
|
|
. round() now validates the value of the $mode parameter and throws a ValueError
|
|
|
|
for invalid modes. Previously invalid modes would have been interpreted as
|
|
|
|
PHP_ROUND_HALF_UP.
|
2023-11-04 21:54:30 +08:00
|
|
|
. strcspn() with empty $characters now returns the length of the string instead
|
|
|
|
of incorrectly stopping at the first NUL character. See GH-12592.
|
2024-08-13 00:56:02 +08:00
|
|
|
. The str_getcsv() function now throws ValueErrors when the $separator and
|
|
|
|
$enclosure arguments are not one byte long, or if the $escape is not one
|
|
|
|
byte long or the empty string. This aligns the behaviour to be identical
|
|
|
|
to that of fputcsv() and fgetcsv().
|
2023-09-22 23:35:03 +08:00
|
|
|
|
2024-07-21 22:49:43 +08:00
|
|
|
- Tidy:
|
|
|
|
. Failures in the constructor now throw exceptions rather than emitting
|
|
|
|
warnings and having a broken object.
|
|
|
|
|
2023-10-20 20:14:55 +08:00
|
|
|
- XML:
|
|
|
|
. The xml_set_*_handler() functions now declare and check for an effective
|
|
|
|
signature of callable|string|null for the $handler parameters.
|
|
|
|
Moreover, values of type string that correspond to method names,
|
|
|
|
of object set with xml_set_object() are now checked to see if the method
|
|
|
|
exists on the class of the previously passed object.
|
|
|
|
This means that xml_set_object() must now always be called prior to setting
|
|
|
|
method names as callables.
|
|
|
|
Passing an empty string to disable the handler is still allowed,
|
2024-08-09 06:37:49 +08:00
|
|
|
but deprecated.
|
2023-10-20 20:14:55 +08:00
|
|
|
|
2024-04-18 03:51:24 +08:00
|
|
|
- XMLReader:
|
|
|
|
. Passing an invalid character encoding to XMLReader::open() or
|
|
|
|
XMLReader::XML() now throws a ValueError. Passing a string containing NULL
|
|
|
|
bytes previously emitted a warning and now throws a ValueError as well.
|
|
|
|
|
|
|
|
- XMLWriter:
|
|
|
|
. Passing a string containing NULL bytes previously emitted a warning and
|
|
|
|
now throws a ValueError.
|
|
|
|
|
2023-09-30 19:59:08 +08:00
|
|
|
- XSL:
|
|
|
|
. XSLTProcessor::setParameter() will now throw a ValueError when its arguments
|
|
|
|
contain null bytes. This never actually worked correctly in the first place,
|
|
|
|
which is why it throws an exception nowadays.
|
2024-01-13 07:00:26 +08:00
|
|
|
. Failure to call a PHP function callback during evaluation now throws
|
|
|
|
instead of emitting a warning.
|
|
|
|
RFC: https://wiki.php.net/rfc/improve_callbacks_dom_and_xsl
|
2024-01-19 03:28:01 +08:00
|
|
|
. Calling XSLTProcessor::importStyleSheet() with a non-XML object now throws
|
|
|
|
a TypeError instead of a ValueError.
|
2023-09-30 19:59:08 +08:00
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
|
|
|
2. New Features
|
|
|
|
========================================
|
2009-01-29 01:23:28 +08:00
|
|
|
|
2023-06-18 04:26:21 +08:00
|
|
|
- Core:
|
|
|
|
. Added request_parse_body() function that allows parsing RFC1867 (multipart)
|
|
|
|
requests in non-POST HTTP requests.
|
|
|
|
RFC: https://wiki.php.net/rfc/rfc1867-non-post
|
2024-03-09 01:31:24 +08:00
|
|
|
. Getting the debug info for WeakReference will now also output the object
|
|
|
|
it references, or null if the reference is no longer valid.
|
2024-04-13 00:21:13 +08:00
|
|
|
. The output of Closure::__debugInfo() now includes the name, file, and line
|
|
|
|
of the Closure.
|
2023-12-26 20:08:00 +08:00
|
|
|
. new expressions with constructor arguments are now dereferencable, meaning
|
|
|
|
they allow chaining method calls, property accesses, etc. without enclosing
|
|
|
|
the expression in parentheses.
|
|
|
|
RFC: https://wiki.php.net/rfc/new_without_parentheses
|
2024-07-02 15:44:25 +08:00
|
|
|
. Added the #[\Deprecated] attribute.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecated_attribute
|
2024-07-14 17:55:03 +08:00
|
|
|
. Implemented property hooks.
|
|
|
|
RFC: https://wiki.php.net/rfc/property-hooks
|
2023-06-18 04:26:21 +08:00
|
|
|
|
2024-03-03 02:34:03 +08:00
|
|
|
- Curl:
|
|
|
|
. curl_version() returns an additional feature_list value, which is an
|
|
|
|
associative array of all known Curl features, and whether they are
|
|
|
|
supported (true) or not (false).
|
2024-08-12 21:26:24 +08:00
|
|
|
. Added CURL_HTTP_VERSION_3 and CURL_HTTP_VERSION_3ONLY constants (available
|
|
|
|
since libcurl 7.66 and 7.88) as available options for CURLOPT_HTTP_VERSION.
|
2024-03-03 02:34:03 +08:00
|
|
|
|
2023-12-17 15:17:11 +08:00
|
|
|
- Date:
|
|
|
|
. Added static methods
|
|
|
|
DateTime[Immutable]::createFromTimestamp(int|float $timestamp): static.
|
2024-03-06 17:18:22 +08:00
|
|
|
. Added method DateTime[Immutable]::getMicrosecond(): int.
|
2024-02-05 20:14:18 +08:00
|
|
|
. Added method
|
2024-03-06 17:18:22 +08:00
|
|
|
DateTime[Immutable]::setMicrosecond(int $microsecond): static.
|
2023-12-17 15:17:11 +08:00
|
|
|
|
2023-09-09 07:14:26 +08:00
|
|
|
- DOM:
|
|
|
|
. Added constant DOMNode::DOCUMENT_POSITION_DISCONNECTED.
|
|
|
|
. Added constant DOMNode::DOCUMENT_POSITION_PRECEDING.
|
|
|
|
. Added constant DOMNode::DOCUMENT_POSITION_FOLLOWING.
|
|
|
|
. Added constant DOMNode::DOCUMENT_POSITION_CONTAINS.
|
|
|
|
. Added constant DOMNode::DOCUMENT_POSITION_CONTAINED_BY.
|
|
|
|
. Added constant DOMNode::DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC.
|
2024-01-13 07:00:26 +08:00
|
|
|
. It is now possible to pass any callable to registerPhpFunctions().
|
|
|
|
RFC: https://wiki.php.net/rfc/improve_callbacks_dom_and_xsl
|
2023-09-09 07:14:26 +08:00
|
|
|
|
2023-11-26 07:11:22 +08:00
|
|
|
- FPM:
|
|
|
|
. Flushing headers without a body will now succeed. See GH-12785.
|
|
|
|
|
2024-06-28 01:29:37 +08:00
|
|
|
- Hash:
|
|
|
|
. Added HashContext::__debugInfo().
|
|
|
|
|
2024-03-03 02:34:03 +08:00
|
|
|
- Intl:
|
|
|
|
. NumberFormatter::ROUND_HALFODD added to complement existing
|
|
|
|
NumberFormatter::ROUND_HALFEVEN functionality.
|
|
|
|
|
2024-04-26 19:26:46 +08:00
|
|
|
- OpenSSL:
|
|
|
|
. Added support for Curve25519 + Curve448 based keys. Specifically x25519,
|
|
|
|
ed25519, x448 and ed448 fields are supported in openssl_pkey_new and
|
|
|
|
openssl_pkey_get_details as well as openssl_sign and openssl_verify were
|
|
|
|
extended to support those keys.
|
2024-05-30 01:06:18 +08:00
|
|
|
|
2024-06-18 05:51:41 +08:00
|
|
|
- PDO:
|
|
|
|
. Added support for driver specific SQL parsers. The default parser supports:
|
|
|
|
- single and double quoted literals, with doubling as escaping mechanism.
|
|
|
|
- two-dashes and non-nested C-style comments.
|
|
|
|
|
|
|
|
- PDO_MYSQL:
|
|
|
|
. Added custom parser supporting:
|
|
|
|
- single and double-quoted literals, with doubling and backslash as escaping
|
|
|
|
mechanism
|
|
|
|
- backtick literal identifiers and with doubling as escaping mechanism
|
|
|
|
- two dashes followed by at least 1 whitespace, non-nested C-style comments,
|
|
|
|
and hash-comments
|
|
|
|
|
|
|
|
- PDO_PGSQL:
|
|
|
|
. Added custom parser supporting:
|
|
|
|
- single and double quoted literals, with doubling as escaping mechanism
|
|
|
|
- C-style "escape" string literals (E'string')
|
|
|
|
- dollar-quoted string literals
|
|
|
|
- two-dashes and C-style comments (non-nested)
|
|
|
|
- support for "??" as escape sequence for the "?" operator
|
|
|
|
|
|
|
|
- PDO_SQLITE:
|
|
|
|
. Added custom parser supporting:
|
|
|
|
- single, double quoted, and backtick literals, with doubling as escaping mechanism
|
|
|
|
- square brackets quoting for identifiers
|
|
|
|
- two-dashes and C-style comments (non-nested)
|
2024-04-26 19:26:46 +08:00
|
|
|
|
2023-10-29 01:48:01 +08:00
|
|
|
- Phar:
|
|
|
|
. Added support for the unix timestamp extension for zip archives.
|
|
|
|
|
2024-02-17 21:15:04 +08:00
|
|
|
- PCRE:
|
2024-06-08 19:03:31 +08:00
|
|
|
. The bundled pcre2lib has been updated to version 10.44.
|
2024-02-17 21:15:04 +08:00
|
|
|
As a consequence, LoongArch JIT support has been added, spaces
|
|
|
|
are now allowed between braces in Perl-compatible items, and
|
|
|
|
variable-length lookbehind assertions are now supported.
|
2024-06-08 19:03:31 +08:00
|
|
|
. With pcre2lib version 10.44, the maximum length of named capture groups
|
|
|
|
has changed from 32 to 128.
|
2024-03-06 03:51:04 +08:00
|
|
|
. Added support for the "r" (PCRE2_EXTRA_CASELESS_RESTRICT) modifier, as well
|
|
|
|
as the (?r) mode modifier. When enabled along with the case-insensitive
|
|
|
|
modifier ("i"), the expression locks out mixing of ASCII and non-ASCII
|
|
|
|
characters.
|
2024-02-17 21:15:04 +08:00
|
|
|
|
2024-01-12 05:58:28 +08:00
|
|
|
- PDO:
|
|
|
|
. Added support for driver-specific subclasses.
|
|
|
|
RFC: https://wiki.php.net/rfc/pdo_driver_specific_subclasses
|
|
|
|
This RFC adds subclasses for PDO in order to better support
|
|
|
|
database-specific functionalities. The new classes are
|
|
|
|
instantiatable either via calling the PDO::connect() method
|
|
|
|
or by invoking their constructor directly.
|
|
|
|
|
2024-02-05 06:02:58 +08:00
|
|
|
- PDO_DBLIB:
|
2024-06-09 10:04:51 +08:00
|
|
|
. Added class Pdo\DbLib.
|
2024-01-12 05:58:28 +08:00
|
|
|
|
2024-02-05 06:02:58 +08:00
|
|
|
- PDO_FIREBIRD:
|
2024-06-09 10:04:51 +08:00
|
|
|
. Added class Pdo\Firebird.
|
2024-01-12 05:58:28 +08:00
|
|
|
|
2024-02-05 06:02:58 +08:00
|
|
|
- PDO_MYSQL:
|
2024-06-09 10:04:51 +08:00
|
|
|
. Added class Pdo\Mysql.
|
2024-01-12 05:58:28 +08:00
|
|
|
|
2024-02-05 06:02:58 +08:00
|
|
|
- PDO_ODBC:
|
2024-06-09 10:04:51 +08:00
|
|
|
. Added class Pdo\Odbc.
|
2024-01-12 05:58:28 +08:00
|
|
|
|
2024-02-05 06:02:58 +08:00
|
|
|
- PDO_PGSQL:
|
2024-06-09 10:04:51 +08:00
|
|
|
. Added class Pdo\Pgsql.
|
2024-01-12 05:58:28 +08:00
|
|
|
|
2024-02-05 06:02:58 +08:00
|
|
|
- PDO_SQLITE:
|
2024-06-09 10:04:51 +08:00
|
|
|
. Added class Pdo\Sqlite.
|
2024-01-12 05:58:28 +08:00
|
|
|
|
2023-11-16 17:36:20 +08:00
|
|
|
- POSIX:
|
|
|
|
. Added constant POSIX_SC_CHILD_MAX
|
|
|
|
. Added constant POSIX_SC_CLK_TCK
|
|
|
|
|
2024-04-08 17:51:24 +08:00
|
|
|
- Readfile:
|
|
|
|
. Added ability to change .php_history path through PHP_HISTFILE env variable.
|
|
|
|
|
2023-12-10 04:37:52 +08:00
|
|
|
- Reflection:
|
|
|
|
. ReflectionAttribute now contains a $name property to improve the debugging
|
|
|
|
experience.
|
2024-02-25 23:02:09 +08:00
|
|
|
. ReflectionClassConstant::__toString() and ReflectionProperty::__toString()
|
|
|
|
now returns the attached doc comments.
|
2024-03-11 08:14:29 +08:00
|
|
|
. ReflectionConstant was introduced.
|
2024-04-30 23:26:27 +08:00
|
|
|
. ReflectionClassConstant::isDeprecated() was introduced.
|
2024-05-30 01:07:09 +08:00
|
|
|
. ReflectionGenerator::isClosed() was introduced.
|
2023-12-10 04:37:52 +08:00
|
|
|
|
2024-04-12 02:16:54 +08:00
|
|
|
- Standard:
|
|
|
|
. stream_bucket_make_writeable() and stream_bucket_new() will now return a
|
2024-08-10 09:52:51 +08:00
|
|
|
StreamBucket instance instead of an instance of stdClass.
|
2024-04-12 02:16:54 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/dedicated_stream_bucket
|
2024-07-19 02:44:30 +08:00
|
|
|
. Added a new RoundingMode enum with clearer naming and improved discoverability
|
|
|
|
compared to the PHP_ROUND_* constants.
|
|
|
|
RFC: https://wiki.php.net/rfc/correctly_name_the_rounding_mode_and_make_it_an_enum
|
2024-04-12 02:16:54 +08:00
|
|
|
|
2023-10-12 11:30:04 +08:00
|
|
|
- SOAP:
|
|
|
|
. Added support for clark notation for namespaces in class map.
|
|
|
|
It is now possible to specify entries in a class map with clark notation
|
|
|
|
to resolve a type with a specific namespace to a specific class.
|
|
|
|
For example: '{http://example.com}foo' => 'FooClass'.
|
2023-10-14 23:57:45 +08:00
|
|
|
. Instances of DateTimeInterface that are passed to xsd:datetime or similar
|
|
|
|
elements are now serialized as such instead of being serialized as an
|
|
|
|
empty string.
|
2024-05-30 01:51:49 +08:00
|
|
|
. Session persistence now works with a shared session module.
|
2023-10-12 11:30:04 +08:00
|
|
|
|
2023-09-30 19:59:08 +08:00
|
|
|
- XSL:
|
|
|
|
. It is now possible to use parameters that contain both single and double
|
|
|
|
quotes.
|
2024-01-13 07:00:26 +08:00
|
|
|
. It is now possible to pass any callable to registerPhpFunctions().
|
|
|
|
RFC: https://wiki.php.net/rfc/improve_callbacks_dom_and_xsl
|
2024-04-01 03:21:23 +08:00
|
|
|
. Added XSLTProcessor::$maxTemplateDepth and XSLTProcessor::$maxTemplateVars
|
|
|
|
to control the recursion depth of XSL template evaluation.
|
2023-09-30 19:59:08 +08:00
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
3. Changes in SAPI modules
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2009-01-29 01:23:28 +08:00
|
|
|
|
2024-07-08 06:07:55 +08:00
|
|
|
- apache2handler
|
|
|
|
. Support for EOL Apache 2.0 and 2.2 has been removed. Minimum required Apache
|
|
|
|
version is now 2.4.
|
|
|
|
|
2024-06-27 19:47:32 +08:00
|
|
|
- FPM:
|
|
|
|
. /dev/poll events.mechanism setting for Solaris/Illumos had been retired.
|
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
4. Deprecated Functionality
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2009-01-29 01:23:28 +08:00
|
|
|
|
2024-03-14 04:40:26 +08:00
|
|
|
- Core:
|
|
|
|
. Implicitly nullable parameter types are now deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecate-implicitly-nullable-types
|
2024-08-09 22:51:07 +08:00
|
|
|
. Passing E_USER_ERROR to trigger_error() is now deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_passing_e_user_error_to_trigger_error
|
2024-08-12 23:10:30 +08:00
|
|
|
. Using "_" as a class name is now deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_using_a_single_underscore_as_a_class_name
|
2024-03-14 04:40:26 +08:00
|
|
|
|
2024-01-10 17:41:24 +08:00
|
|
|
- Curl:
|
|
|
|
. The CURLOPT_BINARYTRANSFER constant is deprecated.
|
|
|
|
|
2023-11-19 05:37:11 +08:00
|
|
|
- Date:
|
|
|
|
. Calling DatePeriod::__construct(string $isostr, int $options = 0) is
|
|
|
|
deprecated. Use DatePeriod::createFromISO8601String() instead.
|
2024-08-05 02:07:52 +08:00
|
|
|
. Constants SUNFUNCS_RET_TIMESTAMP, SUNFUNCS_RET_STRING, and
|
|
|
|
SUNFUNCS_RET_DOUBLE are now deprecated, following the deprecation of
|
|
|
|
the associated date_sunset() and date_sunrise() functions in PHP 8.1.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4
|
2023-11-19 05:37:11 +08:00
|
|
|
|
2024-08-09 01:59:30 +08:00
|
|
|
- DBA:
|
|
|
|
. Passing null or false to dba_key_split() is deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_passing_null_and_false_to_dba_key_split
|
|
|
|
|
2024-08-05 04:00:01 +08:00
|
|
|
- DOM:
|
|
|
|
. Deprecated DOM_PHP_ERR constant.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_dom_php_err_constant
|
|
|
|
|
2024-08-07 01:13:09 +08:00
|
|
|
- Hash:
|
|
|
|
. Deprecated passing incorrect data types for options to ext/hash functions.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4
|
|
|
|
|
2023-11-19 05:55:52 +08:00
|
|
|
- Intl:
|
|
|
|
. Calling intlcal_set() as well as calling IntlCalendar::set() with
|
|
|
|
more than 2 arguments is deprecated. Use either IntlCalendar::setDate()
|
|
|
|
or IntlCalendar::setDateTime() instead.
|
2023-11-19 06:21:55 +08:00
|
|
|
. Calling intlgregcal_create_instance() as well as calling
|
|
|
|
IntlGregorianCalendar::__construct() with more than 2 arguments is
|
|
|
|
deprecated. Use either IntlGregorianCalendar::createFromDate() or
|
|
|
|
IntlGregorianCalendar::createFromDateTime() instead.
|
|
|
|
|
2023-11-20 00:21:11 +08:00
|
|
|
- LDAP:
|
|
|
|
. Calling ldap_connect() with more than 2 arguments is deprecated. Use
|
|
|
|
ldap_connect_wallet() instead.
|
2023-11-20 00:42:54 +08:00
|
|
|
. Calling ldap_exop() with more than 4 arguments is deprecated. Use
|
|
|
|
ldap_exop_sync() instead.
|
2023-11-20 00:21:11 +08:00
|
|
|
|
2024-08-11 20:48:17 +08:00
|
|
|
- Mysqli:
|
|
|
|
. The mysqli_ping() function and mysqli::ping() method are now deprecated,
|
|
|
|
as the reconnect feature was removed in PHP 8.2.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#mysqli_ping_and_mysqliping
|
|
|
|
. The mysqli_kill() function and mysqli::kill() method are now deprecated.
|
|
|
|
If this functionality is needed a SQL "KILL" command can be used instead.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_mysqli_kill
|
|
|
|
. The mysqli_refresh() function and mysqli::refresh() method are now deprecated.
|
|
|
|
If this functionality is needed a SQL "FLUSH" command can be used instead.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_mysqli_refresh
|
2024-08-12 02:25:35 +08:00
|
|
|
. Passing explicitly the $mode parameter to mysqli_store_result() has been
|
|
|
|
deprecated. As the MYSQLI_STORE_RESULT_COPY_DATA constant was only used in
|
|
|
|
conjunction with this function it has also been deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_the_second_parameter_to_mysqli_store_result
|
2024-08-11 20:48:17 +08:00
|
|
|
|
2024-06-18 05:51:41 +08:00
|
|
|
- PDO_PGSQL:
|
|
|
|
. Using escaped question marks (??) inside dollar-quoted strings is deprecated.
|
|
|
|
Since PDO_PGSQL has its own SQL parser with dollar-quoted strings support, it
|
|
|
|
is no longer necessary to escape question marks inside them.
|
|
|
|
|
2023-11-20 03:57:18 +08:00
|
|
|
- PgSQL:
|
|
|
|
. Calling pgsql_fetch_result() with 2 arguments is deprecated. Use the
|
|
|
|
3-parameter signature with a null $row parameter instead.
|
|
|
|
. Calling pg_field_prtlen() with 2 arguments is deprecated. Use the
|
|
|
|
3-parameter signature with a null $row parameter instead.
|
|
|
|
. Calling pg_field_is_null() with 2 arguments is deprecated. Use the
|
|
|
|
3-parameter signature with a null $row parameter instead.
|
2024-05-12 12:33:22 +08:00
|
|
|
. Added pg_result_memory_size to get the visibility the memory used by a query result.
|
2023-11-20 03:57:18 +08:00
|
|
|
|
2024-08-05 00:24:21 +08:00
|
|
|
- Random:
|
|
|
|
. lcg_value() is deprecated, as the function is broken in multiple ways.
|
|
|
|
Use \Random\Randomizer::getFloat() instead.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4
|
|
|
|
|
2023-11-20 18:34:40 +08:00
|
|
|
- Reflection:
|
|
|
|
. Calling ReflectionMethod::__construct() with 1 argument is deprecated.
|
|
|
|
Use ReflectionMethod::createFromMethodName() instead.
|
|
|
|
|
2023-11-23 06:02:25 +08:00
|
|
|
- Session:
|
|
|
|
. Calling session_set_save_handler() with more than 2 arguments is
|
|
|
|
deprecated. Use the 2-parameter signature instead.
|
2024-08-05 00:25:31 +08:00
|
|
|
. Changing the INI settings session.sid_length and session.sid_bits_per_character
|
|
|
|
is deprecated. Update the session storage backend to accept 32 character
|
|
|
|
hexadecimal session IDs and stop changing these two INI settings.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4
|
2023-11-23 06:02:25 +08:00
|
|
|
|
2024-08-10 00:41:02 +08:00
|
|
|
- SOAP:
|
|
|
|
. Passing an int to SoapServer::addFunction() is now deprecated.
|
|
|
|
If all PHP functions need to be provided flatten the array returned by
|
|
|
|
get_defined_functions().
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_soap_functions_all_constant_and_passing_it_to_soapserveraddfunction
|
|
|
|
. The SOAP_FUNCTIONS_ALL constant is now deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_soap_functions_all_constant_and_passing_it_to_soapserveraddfunction
|
|
|
|
|
2024-08-09 02:31:51 +08:00
|
|
|
- SPL:
|
|
|
|
. The SplFixedArray::__wakeup() method has been deprecated as it implements
|
|
|
|
__serialize() and __unserialize() which need to be overwritten instead.
|
2024-08-12 23:09:56 +08:00
|
|
|
. Passing a non-empty string for the $enclosure parameter of:
|
|
|
|
- SplFileObject::setCsvControl()
|
|
|
|
- SplFileObject::fputcsv()
|
|
|
|
- SplFileObject::fgetcsv()
|
|
|
|
is now deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_proprietary_csv_escaping_mechanism
|
2024-08-09 02:31:51 +08:00
|
|
|
|
2023-11-24 21:57:23 +08:00
|
|
|
- Standard:
|
|
|
|
. Calling stream_context_set_option() with 2 arguments is deprecated.
|
|
|
|
Use stream_context_set_options() instead.
|
2023-12-23 21:19:41 +08:00
|
|
|
. Raising zero to the power of negative number is deprecated.
|
2024-08-10 09:52:51 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/raising_zero_to_power_of_negative_number
|
2024-08-05 00:23:19 +08:00
|
|
|
. Unserializing strings using the uppercase 'S' tag is deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4
|
2024-08-12 23:09:56 +08:00
|
|
|
. Passing a non-empty string for the $enclosure parameter of:
|
|
|
|
- fputcsv()
|
|
|
|
- fgetcsv()
|
|
|
|
- str_getcsv()
|
|
|
|
is now deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#deprecate_proprietary_csv_escaping_mechanism
|
2023-11-24 21:57:23 +08:00
|
|
|
|
2024-08-09 06:37:49 +08:00
|
|
|
- XML:
|
|
|
|
. The xml_set_object() function has been deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#xml_set_object_and_xml_set_handler_with_string_method_names
|
|
|
|
. Passing non-callable strings to the xml_set_*_handler() functions is now
|
|
|
|
deprecated.
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#xml_set_object_and_xml_set_handler_with_string_method_names
|
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
5. Changed Functions
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2009-06-24 03:40:31 +08:00
|
|
|
|
2024-01-18 00:15:55 +08:00
|
|
|
- Core:
|
|
|
|
. trigger_error() and user_error() now have a return type of true instead of
|
|
|
|
bool.
|
|
|
|
|
2023-12-17 02:06:56 +08:00
|
|
|
- DOM:
|
|
|
|
. DOMDocument::registerNodeClass() now has a tentative return type of true.
|
|
|
|
Previously, the return type was bool but only true could be returned in practice.
|
|
|
|
|
2024-06-06 01:49:07 +08:00
|
|
|
- GD:
|
|
|
|
. imagejpeg/imagewebp/imagepng/imageavif throws an exception if an invalid
|
|
|
|
quality parameter value is passed. In addition, imageavif will throw an exception
|
|
|
|
if an invalid speed parameter value is passed.
|
2024-06-19 02:27:58 +08:00
|
|
|
. imagescale throws an exception if the width/height argument underflows/overflows or
|
|
|
|
if the mode argument is invalid.
|
|
|
|
imagefilter with IMG_FILTER_SCATTER throws an exception if the sub/plus arguments
|
|
|
|
underflows/overflows.
|
2024-06-06 01:49:07 +08:00
|
|
|
|
2024-03-02 19:04:22 +08:00
|
|
|
- Gettext:
|
2024-03-13 04:24:16 +08:00
|
|
|
. bind_textdomain_codeset, textdomain and d(*)gettext functions now throw an exception
|
|
|
|
if the domain argument is empty.
|
2024-03-02 19:04:22 +08:00
|
|
|
|
2024-03-10 03:02:50 +08:00
|
|
|
- Hash:
|
|
|
|
. Changed the return type of hash_update() to true. It was already the case that only
|
|
|
|
true could be returned, but the stub was not updated yet.
|
|
|
|
|
2023-12-05 06:00:17 +08:00
|
|
|
- Intl:
|
|
|
|
. IntlDateFormatter::__construct() throws a ValueError if the locale is invalid.
|
|
|
|
. NumberFormatter::__construct() throws a ValueError if the locale is invalid.
|
2023-12-21 20:28:05 +08:00
|
|
|
. NumberFormatter::ROUND_TOWARD_ZERO and NumberFormatter::ROUND_AWAY_FROM_ZERO
|
|
|
|
have been added as aliases for NumberFormatter::ROUND_DOWN and
|
|
|
|
NumberFormatter::ROUND_UP to be consistent with the new PHP_ROUND_* modes.
|
|
|
|
RFC: https://wiki.php.net/rfc/new_rounding_modes_to_round_function
|
2024-02-27 01:03:17 +08:00
|
|
|
. ResourceBundle::get() now has a tentative return type of:
|
|
|
|
ResourceBundle|array|string|int|null
|
2023-12-05 06:00:17 +08:00
|
|
|
|
2024-05-20 22:56:38 +08:00
|
|
|
- LibXML:
|
|
|
|
. libxml_set_streams_context() now immediately throws a TypeError when a
|
|
|
|
non-stream-context resource is passed to the function, instead of throwing
|
|
|
|
later when the stream context is used.
|
|
|
|
|
2023-10-24 03:59:08 +08:00
|
|
|
- MBString:
|
|
|
|
. The behavior of mb_strcut is more consistent now on invalid UTF-8 and UTF-16
|
|
|
|
strings. (For valid UTF-8 and UTF-16 strings, there is no change.)
|
|
|
|
|
2023-12-20 07:14:53 +08:00
|
|
|
- OpenSSL:
|
|
|
|
. The extra_attributes parameter in openssl_csr_new sets CSR attributes
|
|
|
|
instead of subject DN which was incorrectly done previously.
|
2023-12-21 00:11:30 +08:00
|
|
|
. The dn parameter in openssl_csr_new allows setting array of values for
|
|
|
|
a single entry.
|
2023-12-23 06:26:49 +08:00
|
|
|
. New serial_hex parameter added to openssl_csr_sign to allow setting serial
|
|
|
|
number in the hexadecimal format.
|
2024-06-02 23:09:41 +08:00
|
|
|
. Parsing ASN.1 UTCTime by openssl_x509_parse fails if seconds are omitted
|
|
|
|
for OpenSSL version below 3.2 (-1 is returned for such fields). The
|
|
|
|
OpenSSL version 3.3+ does not load such certificates already.
|
2023-12-20 07:14:53 +08:00
|
|
|
|
Make ext/odbc default value handling more consistent (#13910)
These changes are carved off from https://github.com/php/php-src/pull/12040/files. I noticed that there are some inconsistencies between odbc_fetch_object()/odbc_fetch_array(), odbc_fetch_into(), as well as odbc_fetch_row(), specifically in how they handle the $row parameter. Now, I tried to align their behaviour the following way:
- I made null the default value. Previously, the default values were one of the following: -1, -1, 0, and null, respectively.
- odbc_fetch_row() has been returning false indicating there is no more rows when 0 is passed as $row. Now, a warning is also emitted in this case, because the null default value is not new, because it's available since PHP 8.0.
- When HAVE_SQL_EXTENDED_FETCH is not defined, the $row parameter is always ignored. Previously, some of the functions didn't accept it at all. Now a warning is emitted if the feature is not supported, but the parameter has any meaningful value (is greater than or equal to 1).
2024-04-11 04:49:41 +08:00
|
|
|
- ODBC:
|
|
|
|
. Parameter $row of odbc_fetch_object(), odbc_fetch_array(), and
|
|
|
|
odbc_fetch_into() now has a default value of null, consistent with
|
|
|
|
odbc_fetch_row(). Previously, the default values were -1, -1, and 0,
|
|
|
|
respectively.
|
|
|
|
|
2024-01-08 05:16:26 +08:00
|
|
|
- Output:
|
|
|
|
. Output handler status flags passed to the flags parameter of ob_start
|
|
|
|
are now cleared.
|
|
|
|
|
2023-12-05 00:05:30 +08:00
|
|
|
- PDO:
|
|
|
|
. getAttribute, enabled to get the value of ATTR_STRINGIFY_FETCHES.
|
|
|
|
|
|
|
|
- PDO_FIREBIRD:
|
2024-04-10 09:02:24 +08:00
|
|
|
. getAttribute, enabled to get values of FB_ATTR_DATE_FORMAT, FB_ATTR_TIME_FORMAT,
|
2023-12-05 00:05:30 +08:00
|
|
|
FB_ATTR_TIMESTAMP_FORMAT.
|
2023-12-08 01:34:55 +08:00
|
|
|
. Added new attributes to specify transaction isolation level and access mode.
|
2024-07-18 07:12:17 +08:00
|
|
|
Along with these, five constants (Pdo\Firebird::TRANSACTION_ISOLATION_LEVEL,
|
|
|
|
Pdo\Firebird::READ_COMMITTED, Pdo\Firebird::REPEATABLE_READ,
|
|
|
|
Pdo\Firebird::SERIALIZABLE, Pdo\Firebird::WRITABLE_TRANSACTION) have been added.
|
2023-12-20 23:37:39 +08:00
|
|
|
. When using persistent connections, there is now a liveness check in the
|
|
|
|
constructor.
|
2024-07-17 19:32:37 +08:00
|
|
|
. The content that is built changes depending on the value of FB_API_VER in
|
2024-07-18 10:17:52 +08:00
|
|
|
ibase.h, so added static method Pdo\Firebird::getApiVersion() to obtain that
|
|
|
|
value. This value can also be referenced from phpinfo.
|
2024-07-09 21:58:02 +08:00
|
|
|
. Five new data types are now available: INT128, DEC16, DEC34, TIMESTAMP_TZ, TIME_TZ.
|
|
|
|
These are available starting with Firebird 4.0.
|
2023-12-05 00:05:30 +08:00
|
|
|
|
|
|
|
- PDO_MYSQL:
|
|
|
|
. getAttribute, enabled to get the value of ATTR_FETCH_TABLE_NAMES.
|
|
|
|
|
2024-05-15 19:15:33 +08:00
|
|
|
- PDO_PGSQL:
|
|
|
|
. getAttribute() can now retrieve the memory usage of query results.
|
|
|
|
PDO::PGSQL_ATTR_RESULT_MEMORY_SIZE was added for this feature.
|
|
|
|
|
2023-10-09 01:26:02 +08:00
|
|
|
- PGSQL:
|
|
|
|
. pg_select, the conditions arguments accepts an empty array and is optional.
|
|
|
|
|
2024-04-09 05:26:14 +08:00
|
|
|
- POSIX:
|
|
|
|
. posix_isatty now sets the error number when the file descriptor/stream argument
|
|
|
|
is invalid.
|
|
|
|
|
2024-05-21 14:54:51 +08:00
|
|
|
- Reflection:
|
|
|
|
. ReflectionGenerator::getFunction() may now be called after the generator
|
|
|
|
finished executing.
|
|
|
|
|
2024-03-31 23:07:39 +08:00
|
|
|
- Sockets:
|
|
|
|
. Parameter $backlog of socket_create_listen() now has a default value of SOMAXCONN.
|
|
|
|
Previously, it was 128.
|
|
|
|
|
2024-01-15 18:09:38 +08:00
|
|
|
- SPL:
|
|
|
|
. SplPriorityQueue::insert() and SplPriorityQueue::recoverFromCorruption()
|
|
|
|
now has a tentative return type of true
|
|
|
|
. SplHeap::insert() and SplHeap::recoverFromCorruption()
|
|
|
|
now has a tentative return type of true instead of bool
|
|
|
|
|
2023-09-20 00:05:05 +08:00
|
|
|
- Standard:
|
|
|
|
. The internal implementation for rounding to integers has been rewritten
|
|
|
|
to be easier to verify for correctness and to be easier to maintain.
|
|
|
|
Some rounding bugs have been fixed as a result of the rewrite. For
|
|
|
|
example previously rounding 0.49999999999999994 to the nearest integer
|
|
|
|
would have resulted in 1.0 instead of the correct result 0.0. Additional
|
|
|
|
inputs might also be affected and result in different outputs compared to
|
|
|
|
earlier PHP versions.
|
2024-07-19 02:44:30 +08:00
|
|
|
. The $mode parameter of the round() function has been widened to RoundingMode|int,
|
|
|
|
accepting instances of a new RoundingMode enum.
|
2023-10-06 20:27:01 +08:00
|
|
|
|
2024-07-19 02:44:30 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/correctly_name_the_rounding_mode_and_make_it_an_enum
|
|
|
|
. Four new modes have been added to the round() function: RoundingMode::PositiveInfinity,
|
|
|
|
RoundingMode::NegativeInfinity, RoundingMode::TowardsZero, RoundingMode::AwayFromZero.
|
2023-12-21 20:28:05 +08:00
|
|
|
|
|
|
|
RFC: https://wiki.php.net/rfc/new_rounding_modes_to_round_function
|
2024-02-03 21:23:02 +08:00
|
|
|
. Fixed a bug caused by "pre-rounding" of the round() function. Previously, using
|
|
|
|
"pre-rounding" to treat a value like 0.285 (actually 0.28499999999999998) as a
|
|
|
|
decimal number and round it to 0.29. However, "pre-rounding" incorrectly rounds
|
|
|
|
certain numbers, so this fix removes "pre-rounding" and changes the way numbers
|
2024-04-10 09:02:24 +08:00
|
|
|
are compared, so that the values are correctly rounded as decimal numbers.
|
2024-07-29 19:39:35 +08:00
|
|
|
. The maximum precision that can be handled by round() has been extended by one
|
|
|
|
digit. For example, `round(4503599627370495.5)` returned in `4503599627370495.5`,
|
|
|
|
but now returns `4503599627370496`.
|
2024-07-19 02:44:30 +08:00
|
|
|
. The default value of the 'cost' option for PASSWORD_BCRYPT for password_hash()
|
|
|
|
has been increased from '10' to '12'.
|
|
|
|
|
|
|
|
RFC: https://wiki.php.net/rfc/bcrypt_cost_2023
|
|
|
|
. debug_zval_dump() now indicates whether an array is packed.
|
|
|
|
. long2ip() now returns string instead of string|false.
|
2024-02-01 04:23:14 +08:00
|
|
|
. output_add_rewrite_var() now uses url_rewriter.hosts instead of
|
|
|
|
session.trans_sid_hosts for selecting hosts that will be rewritten.
|
2024-07-16 05:20:32 +08:00
|
|
|
. highlight_string() now has a return type of string|true instead of string|bool.
|
|
|
|
. print_r() now has a return type of string|true instead of string|bool.
|
2023-09-20 00:05:05 +08:00
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
6. New Functions
|
2022-09-05 02:59:26 +08:00
|
|
|
========================================
|
2022-09-05 02:52:21 +08:00
|
|
|
|
2024-05-01 21:02:38 +08:00
|
|
|
- BCMath:
|
|
|
|
. Added bcfloor(), bcceil(), bcround().
|
|
|
|
RFC: https://wiki.php.net/rfc/adding_bcround_bcfloor_bcceil_to_bcmath
|
|
|
|
|
2023-09-09 07:14:26 +08:00
|
|
|
- DOM:
|
|
|
|
. Added DOMNode::compareDocumentPosition().
|
2024-01-13 07:00:26 +08:00
|
|
|
. Added DOMXPath::registerPhpFunctionNS().
|
|
|
|
RFC: https://wiki.php.net/rfc/improve_callbacks_dom_and_xsl
|
2024-02-23 03:32:32 +08:00
|
|
|
. Added DOMXPath::quote() to quote a string for use in an XPath expression.
|
|
|
|
Example usage: "//span[contains(text()," . $xpath->quote($string) . ")]"
|
2023-09-09 07:14:26 +08:00
|
|
|
|
2024-02-22 00:24:27 +08:00
|
|
|
- Intl:
|
|
|
|
. Added IntlDateFormatter::getIanaID()/intltz_get_iana_id() to
|
|
|
|
the IANA identifier from a given timezone.
|
2024-03-03 00:09:26 +08:00
|
|
|
. Added grapheme_str_split which allow to support emoji and Variation
|
|
|
|
Selectors.
|
2024-08-10 09:52:51 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/grapheme_str_split
|
2024-03-22 03:44:02 +08:00
|
|
|
. Added IntlDateFormatter::parseToCalendar which behaves like
|
|
|
|
IntlDateFormatter::parse except the time zone is updated.
|
2024-06-02 19:47:53 +08:00
|
|
|
. Added SpoofChecker::setAllowedChars to limit the range of unicode
|
|
|
|
chars.
|
2024-02-22 00:24:27 +08:00
|
|
|
|
2023-11-24 18:47:32 +08:00
|
|
|
- MBString:
|
|
|
|
. Added mb_trim, mb_ltrim and mb_rtrim functions.
|
|
|
|
RFC: https://wiki.php.net/rfc/mb_trim
|
2024-04-24 15:10:13 +08:00
|
|
|
Note: this was amended by GH-13820 to fix GH-13815.
|
2024-03-21 00:25:19 +08:00
|
|
|
. Added mb_ucfirst and mb_lcfirst functions.
|
|
|
|
RFC: https://wiki.php.net/rfc/mb_ucfirst
|
2023-11-24 18:47:32 +08:00
|
|
|
|
2024-04-04 01:59:40 +08:00
|
|
|
- PCNTL:
|
|
|
|
. Added pcntl_setns allowing a process to be reassociated with a namespace in order
|
|
|
|
to share resources with other processes within this context.
|
2024-04-06 04:37:59 +08:00
|
|
|
. Added pcntl_getaffinity to get the cpu(s) bound to a process and
|
|
|
|
pcntl_setaffinity to bind 1 or more cpus to a process.
|
2024-04-08 00:08:46 +08:00
|
|
|
. Added pcntl_getcpu to get the cpu id from where the current process runs.
|
2024-04-12 04:14:22 +08:00
|
|
|
. Added pcntl_getqos_class to get the QoS level (aka performance and related
|
|
|
|
energy consumption) of the current process and pcntl_setqos_class to set it.
|
2024-06-20 20:47:27 +08:00
|
|
|
. Added pcntl_waitid to obtain status information pertaining to termination, stop,
|
|
|
|
and/or continue events in one of the caller's child processes.
|
2024-04-04 01:59:40 +08:00
|
|
|
|
2021-03-12 07:16:18 +08:00
|
|
|
- PDO_PGSQL:
|
2024-06-09 10:04:51 +08:00
|
|
|
. Added Pdo\Pgsql::setNoticeCallback() to allow a callback to be triggered on
|
2021-03-12 07:16:18 +08:00
|
|
|
every notice sent (e.g. RAISE NOTICE).
|
|
|
|
|
2024-05-18 14:36:57 +08:00
|
|
|
- PGSQL:
|
|
|
|
. Added pg_change_password to alter a given user's password. It handles
|
|
|
|
transparently the password encryption from the database settings.
|
2024-05-25 23:58:06 +08:00
|
|
|
. Added pg_put_copy_data to send COPY commands and pg_put_copy_end to send
|
|
|
|
end-of-data to the server.
|
2024-05-30 02:55:13 +08:00
|
|
|
. Added pg_socket_poll to check if there is any read and/or write events
|
|
|
|
with an optional timeout.
|
2024-06-14 02:29:02 +08:00
|
|
|
. Added pg_jit to get informations on the server JIT support.
|
2024-06-15 02:06:58 +08:00
|
|
|
. Added pg_set_chunked_rows_size to allow to fetch results in chunk of
|
|
|
|
max N rows.
|
2024-05-18 14:36:57 +08:00
|
|
|
|
2023-12-07 08:31:42 +08:00
|
|
|
- Sodium:
|
|
|
|
. Added the sodium_crypto_aead_aegis128l_*() and sodium_crypto_aead_aegis256l_*()
|
|
|
|
functions to support the AEGIS family of authenticated encryption algorithms,
|
|
|
|
that was introduced in libsodium 1.0.19.
|
|
|
|
. sodium_crypto_aead_aes256gcm_*() functions are now enabled on aarch64 CPUs
|
|
|
|
with the ARM cryptographic extensions.
|
|
|
|
|
2024-05-05 19:26:54 +08:00
|
|
|
- SPL:
|
|
|
|
. Added seek() method to SplObjectStorage, now it implements
|
|
|
|
SeekableIterator.
|
|
|
|
|
2024-03-01 00:41:09 +08:00
|
|
|
- Standard:
|
|
|
|
. Added the http_get_last_response_headers() and
|
|
|
|
http_clear_last_response_headers() that allows retrieving the same content
|
|
|
|
as the magic $http_response_header variable.
|
2024-08-10 09:52:51 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/http-last-response-headers
|
2023-12-23 21:19:41 +08:00
|
|
|
. Added function fpow() following rules of IEEE 754.
|
2024-08-10 09:52:51 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/raising_zero_to_power_of_negative_number
|
2024-06-01 01:39:12 +08:00
|
|
|
. Added functions array_find(), array_find_key(), array_all(), and
|
|
|
|
array_any().
|
|
|
|
RFC: https://wiki.php.net/rfc/array_find
|
2024-03-01 00:41:09 +08:00
|
|
|
|
2024-07-21 07:21:35 +08:00
|
|
|
- Tidy:
|
|
|
|
. Added tidyNode::getNextSibling() and tidyNode::getPreviousSibling().
|
|
|
|
|
2024-04-18 03:51:24 +08:00
|
|
|
- XMLReader:
|
2024-06-28 04:28:50 +08:00
|
|
|
. Added XMLReader::fromStream(), XMLReader::fromUri(), XMLReader::fromString().
|
2024-04-18 03:51:24 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/xmlreader_writer_streams
|
|
|
|
|
|
|
|
- XMLWriter:
|
2024-06-28 03:36:41 +08:00
|
|
|
. Added XMLWriter::toStream(), XMLWriter::toUri(), XMLWriter::toMemory().
|
2024-04-18 03:51:24 +08:00
|
|
|
RFC: https://wiki.php.net/rfc/xmlreader_writer_streams
|
|
|
|
|
2024-01-13 07:00:26 +08:00
|
|
|
- XSL:
|
|
|
|
. Added XSLTProcessor::registerPhpFunctionNS().
|
|
|
|
RFC: https://wiki.php.net/rfc/improve_callbacks_dom_and_xsl
|
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
7. New Classes and Interfaces
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2009-01-29 01:23:28 +08:00
|
|
|
|
2024-08-10 09:52:51 +08:00
|
|
|
- Core:
|
|
|
|
. New RequestParseBodyException.
|
|
|
|
RFC: https://wiki.php.net/rfc/rfc1867-non-post
|
|
|
|
|
2024-03-09 23:56:00 +08:00
|
|
|
- DOM:
|
|
|
|
. Implemented DOM HTML5 parsing and serialization.
|
|
|
|
RFC: https://wiki.php.net/rfc/domdocument_html5_parser.
|
2024-05-09 18:47:39 +08:00
|
|
|
This RFC adds the new Dom namespace along with new classes and
|
2024-03-09 23:56:00 +08:00
|
|
|
constant aliases.
|
|
|
|
There are two new classes to handle HTML and XML documents:
|
2024-05-09 18:47:39 +08:00
|
|
|
Dom\HTMLDocument and Dom\XMLDocument.
|
2024-03-09 23:56:00 +08:00
|
|
|
These classes provide a cleaner API to handle HTML and XML documents.
|
2024-05-09 18:47:39 +08:00
|
|
|
Furthermore, the Dom\HTMLDocument class implements spec-compliant HTML5
|
2024-03-09 23:56:00 +08:00
|
|
|
parsing and serialization.
|
|
|
|
. Implemented opt-in ext/dom spec compliance RFC.
|
|
|
|
This adds new classes in the DOM namespace that correspond to modern
|
|
|
|
equivalents to the old DOM classes in the global namespaces.
|
|
|
|
The new classes follow the DOM living spec.
|
|
|
|
RFC: https://wiki.php.net/rfc/opt_in_dom_spec_compliance
|
2024-06-27 02:39:05 +08:00
|
|
|
. Implemented "New ext-dom features in PHP 8.4" RFC.
|
|
|
|
RFC: https://wiki.php.net/rfc/dom_additions_84
|
2024-03-09 23:56:00 +08:00
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2015-02-10 15:56:18 +08:00
|
|
|
8. Removed Extensions and SAPIs
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2009-01-29 01:23:28 +08:00
|
|
|
|
2024-01-22 20:56:05 +08:00
|
|
|
- IMAP:
|
|
|
|
. The IMAP extension has been unbundled and moved to PECL.
|
|
|
|
RFC: https://wiki.php.net/rfc/unbundle_imap_pspell_oci8
|
|
|
|
|
2024-06-21 15:45:53 +08:00
|
|
|
- OCI8:
|
|
|
|
. The OCI8 extension has been unbundled and moved to PECL.
|
|
|
|
RFC: https://wiki.php.net/rfc/unbundle_imap_pspell_oci8
|
|
|
|
|
|
|
|
- PDO_OCI:
|
|
|
|
. The PDO_OCI extension has been unbundled and moved to PECL.
|
|
|
|
RFC: https://wiki.php.net/rfc/unbundle_imap_pspell_oci8
|
|
|
|
|
2024-01-17 19:21:08 +08:00
|
|
|
- PSpell:
|
|
|
|
. The pspell extension has been unbundled and moved to PECL.
|
|
|
|
RFC: https://wiki.php.net/rfc/unbundle_imap_pspell_oci8
|
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
9. Other Changes to Extensions
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2016-07-03 18:43:30 +08:00
|
|
|
|
2024-01-31 21:48:17 +08:00
|
|
|
- Curl:
|
|
|
|
. The Curl extension now requires at least libcurl 7.61.0.
|
|
|
|
|
2024-05-22 19:17:44 +08:00
|
|
|
- Date:
|
|
|
|
. The class constants are typed now.
|
|
|
|
|
2024-08-05 05:30:52 +08:00
|
|
|
- DOM:
|
|
|
|
. Removed DOMImplementation::getFeature().
|
|
|
|
RFC: https://wiki.php.net/rfc/deprecations_php_8_4#remove_domimplementationgetfeature_feature_version
|
|
|
|
|
2023-10-29 17:50:16 +08:00
|
|
|
- Intl:
|
|
|
|
. The class constants are typed now.
|
2024-05-30 20:02:44 +08:00
|
|
|
. The behaviour of Intl class has been normalized to always throw Error
|
|
|
|
exceptions when attempting to use a non-initialized object,
|
|
|
|
or when cloning fails.
|
|
|
|
. The idn_to_ascii() and idn_to_utf8() now always throw ValueErrors if the
|
|
|
|
$domain name is empty or too long, and if $variant is not
|
|
|
|
INTL_IDNA_VARIANT_UTS46.
|
2023-10-29 17:50:16 +08:00
|
|
|
|
2024-06-27 02:58:14 +08:00
|
|
|
- MBString:
|
|
|
|
. Unicode data tables have been updated to Unicode 15.1.
|
|
|
|
|
2024-06-30 04:21:03 +08:00
|
|
|
- mysqli:
|
|
|
|
. The unused and undocumented constant MYSQLI_SET_CHARSET_DIR
|
|
|
|
has been removed.
|
|
|
|
|
2024-05-30 20:02:44 +08:00
|
|
|
- OpenSSL:
|
2024-02-25 10:37:08 +08:00
|
|
|
. The OpenSSL extension now requires at least OpenSSL 1.1.1.
|
|
|
|
|
2023-10-29 17:43:19 +08:00
|
|
|
- PDO:
|
2023-10-07 20:14:57 +08:00
|
|
|
. The class constants are typed now.
|
|
|
|
|
2024-06-26 02:50:04 +08:00
|
|
|
- pdo_pgsql:
|
|
|
|
. The pdo_pgsql extension now requires at least libpq 10.0.
|
|
|
|
|
|
|
|
- pgsql:
|
|
|
|
. The pgsql extension now requires at least libpq 10.0.
|
|
|
|
|
2023-10-28 15:47:19 +08:00
|
|
|
- Reflection:
|
|
|
|
. The class constants are typed now.
|
|
|
|
|
2023-10-29 17:43:19 +08:00
|
|
|
- Spl:
|
|
|
|
. The class constants are typed now.
|
|
|
|
|
2023-10-29 17:53:07 +08:00
|
|
|
- Sqlite:
|
|
|
|
. The class constants are typed now.
|
|
|
|
|
2024-03-06 03:50:54 +08:00
|
|
|
- XMLReader:
|
|
|
|
. The class constants are typed now.
|
|
|
|
|
2023-11-24 20:37:08 +08:00
|
|
|
- XSL:
|
|
|
|
. The typed properties XSLTProcessor::$cloneDocument and
|
|
|
|
XSLTProcessor::$doXInclude are now declared.
|
|
|
|
|
2024-06-21 21:05:34 +08:00
|
|
|
- zlib:
|
|
|
|
. The zlib extension now requires at least zlib 1.2.11.
|
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
10. New Global Constants
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2010-03-25 00:23:50 +08:00
|
|
|
|
2024-01-04 23:05:49 +08:00
|
|
|
- Core:
|
|
|
|
. PHP_OUTPUT_HANDLER_PROCESSED.
|
2024-05-29 13:04:05 +08:00
|
|
|
. PHP_SBINDIR.
|
2024-01-04 23:05:49 +08:00
|
|
|
|
2024-08-12 21:26:24 +08:00
|
|
|
- Curl:
|
|
|
|
. CURL_HTTP_VERSION_3.
|
|
|
|
. CURL_HTTP_VERSION_3ONLY.
|
|
|
|
|
2023-09-21 12:51:52 +08:00
|
|
|
- Intl:
|
|
|
|
. The IntlDateFormatter class exposes now the new PATTERN constant
|
|
|
|
reflecting udat api's UDAT_PATTERN.
|
2024-02-22 00:24:27 +08:00
|
|
|
. The IntlChar class exposes now the new PROPERTY_IDS_UNARY_OPERATOR (new
|
2024-02-22 07:23:09 +08:00
|
|
|
IDS binary operator), PROPERTY_ID_COMPAT_MATH_START,
|
|
|
|
PROPERTY_ID_COMPAT_MATH_CONTINUE (both for mathematical
|
2024-02-22 00:24:27 +08:00
|
|
|
identifier profiling purpose) constants.
|
2023-09-21 12:51:52 +08:00
|
|
|
|
2024-02-16 02:53:45 +08:00
|
|
|
- LDAP:
|
|
|
|
. LDAP_OPT_X_TLS_PROTOCOL_MAX.
|
|
|
|
. LDAP_OPT_X_TLS_PROTOCOL_TLS1_3.
|
|
|
|
|
2024-02-26 04:03:37 +08:00
|
|
|
- LibXML:
|
|
|
|
. LIBXML_RECOVER.
|
2024-07-06 23:43:46 +08:00
|
|
|
. LIBXML_NO_XXE.
|
|
|
|
This is used together with LIBXML_NOENT for when you want to perform entity
|
|
|
|
substitution, but want to disallow external entity loading.
|
|
|
|
This constant is available as of libxml2 2.13.
|
2024-02-26 04:03:37 +08:00
|
|
|
|
2024-01-15 01:10:12 +08:00
|
|
|
- OpenSSL:
|
|
|
|
. X509_PURPOSE_OCSP_HELPER.
|
|
|
|
. X509_PURPOSE_TIMESTAMP_SIGN.
|
|
|
|
|
2024-04-12 04:14:22 +08:00
|
|
|
- PCNTL:
|
2024-07-10 03:33:09 +08:00
|
|
|
. Pcntl\QosClass::Background (macOs only).
|
|
|
|
. Pcntl\QosClass::Default (macOs only).
|
|
|
|
. Pctnl\QosClass::UserInteractive (macOs only).
|
|
|
|
. Pcntl\QosClass::UserInitiated (macOs only).
|
|
|
|
. Pcntl\QosClass::Utility (macOs only).
|
2024-04-20 03:19:12 +08:00
|
|
|
. SIGCKPT (DragonFlyBSD only).
|
|
|
|
. SIGCKPTEXIT (DragonFlyBSD only).
|
2024-06-20 20:47:27 +08:00
|
|
|
. WEXITED.
|
|
|
|
. WSTOPPED.
|
|
|
|
. WNOWAIT.
|
|
|
|
. P_ALL.
|
|
|
|
. P_PID.
|
|
|
|
. P_PGID.
|
|
|
|
. P_PIDFD (Linux only).
|
2024-07-07 18:06:59 +08:00
|
|
|
. P_UID (NetBSD/FreeBSD only).
|
|
|
|
. P_GID (NetBSD/FreeBSD only).
|
|
|
|
. P_SID (NetBSD/FreeBSD only).
|
2024-06-20 20:47:27 +08:00
|
|
|
. P_JAILID (FreeBSD only).
|
2024-07-17 19:32:37 +08:00
|
|
|
|
2023-12-26 23:20:13 +08:00
|
|
|
- Sockets:
|
|
|
|
. SO_EXCLUSIVEADDRUSE (Windows only).
|
2024-03-16 21:34:40 +08:00
|
|
|
. SOCK_CONN_DGRAM (NetBSD only).
|
|
|
|
. SOCK_DCCP (NetBSD only).
|
2024-03-27 06:59:14 +08:00
|
|
|
. TCP_SYNCNT (Linux only).
|
2024-04-08 05:01:46 +08:00
|
|
|
. SO_EXCLBIND (Solaris/Illumos only).
|
2024-04-28 20:01:49 +08:00
|
|
|
. SO_NOSIGPIPE (macOs and FreeBSD).
|
2024-06-19 04:33:03 +08:00
|
|
|
. SO_LINGER_SEC (macOs only).
|
2024-08-11 02:54:39 +08:00
|
|
|
. IP_PORTRANGE (FreeBSD/NetBSD/OpenBSD only).
|
|
|
|
. IP_PORTRANGE_DEFAULT (FreeBSD/NetBSD/OpenBSD only).
|
|
|
|
. IP_PORTRANGE_HIGH (FreeBSD/NetBSD/OpenBSD only).
|
|
|
|
. IP_PORTRANGE_LOW (FreeBSD/NetBSD/OpenBSD only).
|
2024-08-10 15:03:32 +08:00
|
|
|
. SOCK_NONBLOCK.
|
|
|
|
. SOCK_CLOEXEC.
|
2023-12-26 23:20:13 +08:00
|
|
|
|
2024-03-12 05:16:22 +08:00
|
|
|
- Sodium:
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS128L_KEYBYTES
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS128L_NSECBYTES
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS128L_NPUBBYTES
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS128L_ABYTES
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS256_KEYBYTES
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS256_NSECBYTES
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS256_NPUBBYTES
|
|
|
|
. SODIUM_CRYPTO_AEAD_AEGIS256_ABYTES
|
|
|
|
|
2023-10-22 22:44:49 +08:00
|
|
|
- XML:
|
|
|
|
. Added XML_OPTION_PARSE_HUGE to allow large inputs in xml_parse and
|
|
|
|
xml_parse_into_struct.
|
|
|
|
RFC: https://wiki.php.net/rfc/xml_option_parse_huge.
|
|
|
|
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2014-05-01 18:27:38 +08:00
|
|
|
11. Changes to INI File Handling
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2010-08-30 17:38:47 +08:00
|
|
|
|
2014-08-22 19:35:07 +08:00
|
|
|
========================================
|
|
|
|
12. Windows Support
|
|
|
|
========================================
|
|
|
|
|
2019-01-15 17:13:39 +08:00
|
|
|
========================================
|
2019-01-28 17:34:31 +08:00
|
|
|
13. Other Changes
|
2012-03-06 04:14:04 +08:00
|
|
|
========================================
|
2018-12-27 05:26:01 +08:00
|
|
|
|
2024-04-13 00:21:13 +08:00
|
|
|
* Closure names have been adjusted to include the parent function's name
|
|
|
|
and the line of definition to make them easier to distinguish, for example
|
|
|
|
within stack traces.
|
|
|
|
|
2024-04-29 03:47:13 +08:00
|
|
|
* run-tests.php now skips online tests by default. Set the SKIP_ONLINE_TESTS
|
|
|
|
environment variable to 0, or pass the --online flag to run-tests.php to
|
|
|
|
execute them.
|
|
|
|
|
2024-07-02 21:24:11 +08:00
|
|
|
* Fiber switching during destructor execution is now allowed. It was previously
|
|
|
|
blocked due to conflicts with garbage collection.
|
|
|
|
|
|
|
|
Destructors may now be executed in a separate Fiber:
|
|
|
|
|
|
|
|
When garbage collection is triggered in a Fiber, destructors called by the GC
|
|
|
|
are executed in a separate Fiber: the gc_destructor_fiber. If this Fiber
|
|
|
|
suspends, a new one is created to execute the remaining destructors. The
|
|
|
|
previous gc_destructor_fiber is not referenced anymore by the GC and may be
|
|
|
|
collected if it's not referenced anywhere else. Objects whose destructor is
|
|
|
|
suspended will not be collected until the destructor returns or the Fiber is
|
|
|
|
collected.
|
|
|
|
|
2018-12-27 05:26:01 +08:00
|
|
|
========================================
|
2019-01-28 17:34:31 +08:00
|
|
|
14. Performance Improvements
|
2018-12-27 05:26:01 +08:00
|
|
|
========================================
|
2023-06-20 00:46:05 +08:00
|
|
|
|
2024-05-01 22:57:36 +08:00
|
|
|
- BCMath:
|
2024-05-09 18:46:42 +08:00
|
|
|
. Improved performance of number conversions and operations.
|
2024-05-01 22:57:36 +08:00
|
|
|
|
2024-04-23 17:58:51 +08:00
|
|
|
- Core:
|
|
|
|
. Improved the performance of floating point number parsing and formatting in
|
|
|
|
ZTS builds under highly concurrent loads. This affects the `printf()` family
|
|
|
|
of functions as well as serialization functions such as `json_encode()`,
|
|
|
|
`serialize()`.
|
|
|
|
|
2024-04-14 19:59:46 +08:00
|
|
|
- DOM:
|
|
|
|
. The performance of DOMNode::C14N() is greatly improved for the case without
|
|
|
|
an xpath query. This can give a time improvement of easily two order of
|
|
|
|
magnitude for documents with tens of thousands of nodes.
|
2024-05-12 07:57:29 +08:00
|
|
|
. Improved performance and reduce memory consumption of XML serialization.
|
2024-03-06 03:54:38 +08:00
|
|
|
|
2024-04-14 19:59:46 +08:00
|
|
|
- FTP:
|
|
|
|
. Improved the performance of FTP uploads up to a factor of 10x for large
|
|
|
|
uploads.
|
2023-11-12 01:44:17 +08:00
|
|
|
|
2024-08-09 04:19:33 +08:00
|
|
|
- Hash:
|
|
|
|
. Added SSE2 and SHA-NI implementations of SHA-256. This improves the performance
|
|
|
|
on supported CPUs by ~1.3x (SSE2) and 3x - 5x (SHA-NI).
|
|
|
|
|
2024-04-14 19:59:46 +08:00
|
|
|
- MBString:
|
|
|
|
. The performance of strspn() and strcspn() is greatly improved.
|
|
|
|
They now run in linear time instead of being bounded by quadratic time.
|
|
|
|
. mb_strcut() is much faster now for UTF-8 and UTF-16 strings.
|
|
|
|
. Looking up mbstring encoding names is much faster now.
|
|
|
|
. The performance of converting SJIS-win to unicode is greatly improved.
|
2023-11-24 20:37:08 +08:00
|
|
|
|
2024-04-14 19:59:46 +08:00
|
|
|
- MySQLnd:
|
|
|
|
. Improved the performance of MySQLnd quoting.
|
2023-11-24 20:37:08 +08:00
|
|
|
|
2024-06-04 03:15:26 +08:00
|
|
|
- PCRE:
|
|
|
|
. Improved the performance of named capture groups.
|
|
|
|
|
2024-05-12 07:57:29 +08:00
|
|
|
- SimpleXML:
|
|
|
|
. Improved performance and reduce memory consumption of XML serialization.
|
|
|
|
|
2024-04-14 19:59:46 +08:00
|
|
|
- Standard:
|
|
|
|
. Improved the performance of strpbrk().
|
|
|
|
. get_browser() is much faster now, up to 1.5x - 2.5x for some test cases.
|
2024-03-08 03:26:35 +08:00
|
|
|
|