From bbb6d4d79a3e62b55814e42e36a2dc9db3184077 Mon Sep 17 00:00:00 2001 From: haszi Date: Fri, 5 Jan 2024 21:06:19 +0100 Subject: [PATCH 1/3] Change PHP_ZTS and PHP_DEBUG to bool to match their ZEND equivalents --- main/main.stub.php | 4 ++-- main/main_arginfo.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/main/main.stub.php b/main/main.stub.php index 32ae0e67f249f..7fcf99059bbbb 100644 --- a/main/main.stub.php +++ b/main/main.stub.php @@ -35,12 +35,12 @@ */ const PHP_VERSION_ID = UNKNOWN; /** - * @var int + * @var bool * @cvalue PHP_ZTS */ const PHP_ZTS = UNKNOWN; /** - * @var int + * @var bool * @cvalue PHP_DEBUG */ const PHP_DEBUG = UNKNOWN; diff --git a/main/main_arginfo.h b/main/main_arginfo.h index 0cb3b6e2bed2c..9899443c25158 100644 --- a/main/main_arginfo.h +++ b/main/main_arginfo.h @@ -1,5 +1,5 @@ /* This is a generated file, edit the .stub.php file instead. - * Stub hash: 6c0b61ad50611c52fd76dbbb25089817dc06eff4 */ + * Stub hash: 9447c185f3098fd2c7806e2f8adf4bf395bb18af */ @@ -11,8 +11,8 @@ static void register_main_symbols(int module_number) REGISTER_LONG_CONSTANT("PHP_RELEASE_VERSION", PHP_RELEASE_VERSION, CONST_PERSISTENT); REGISTER_STRING_CONSTANT("PHP_EXTRA_VERSION", PHP_EXTRA_VERSION, CONST_PERSISTENT); REGISTER_LONG_CONSTANT("PHP_VERSION_ID", PHP_VERSION_ID, CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("PHP_ZTS", PHP_ZTS, CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("PHP_DEBUG", PHP_DEBUG, CONST_PERSISTENT); + REGISTER_BOOL_CONSTANT("PHP_ZTS", PHP_ZTS, CONST_PERSISTENT); + REGISTER_BOOL_CONSTANT("PHP_DEBUG", PHP_DEBUG, CONST_PERSISTENT); REGISTER_STRING_CONSTANT("PHP_OS", PHP_OS_STR, CONST_PERSISTENT); REGISTER_STRING_CONSTANT("PHP_OS_FAMILY", PHP_OS_FAMILY, CONST_PERSISTENT); REGISTER_STRING_CONSTANT("DEFAULT_INCLUDE_PATH", PHP_INCLUDE_PATH, CONST_PERSISTENT); From daddc3ec1d5520257a3874c80a2139a73a8c8af1 Mon Sep 17 00:00:00 2001 From: haszi Date: Fri, 5 Jan 2024 21:07:15 +0100 Subject: [PATCH 2/3] Update PHP_ZTS comparison in ZIP test --- ext/zip/tests/bug72660.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/zip/tests/bug72660.phpt b/ext/zip/tests/bug72660.phpt index 900b0bf4fe6f2..9a9625ff7c404 100644 --- a/ext/zip/tests/bug72660.phpt +++ b/ext/zip/tests/bug72660.phpt @@ -4,7 +4,7 @@ Bug #72660 (NULL Pointer dereference in zend_virtual_cwd) zip --SKIPIF-- --FILE-- Date: Sun, 7 Jan 2024 11:29:40 +0100 Subject: [PATCH 3/3] Update NEWS and UPGRADING --- NEWS | 1 + UPGRADING | 3 +++ 2 files changed, 4 insertions(+) diff --git a/NEWS b/NEWS index 7ffa53f5e30bd..0d731289597ad 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,7 @@ Core: . Added zend_call_stack_get implementation for NetBSD, DragonFlyBSD, Solaris and Haiku. (David Carlier) . Enabled ifunc checks on FreeBSD from the 12.x releases. (Freaky) + . Changed the type of PHP_DEBUG and PHP_ZTS constants to bool. (haszi) Date: . Added DateTime[Immutable]::createFromTimestamp. (Marc Bennewitz) diff --git a/UPGRADING b/UPGRADING index 6cbd1270e0550..7ccc9751c0d09 100644 --- a/UPGRADING +++ b/UPGRADING @@ -19,6 +19,9 @@ PHP 8.4 UPGRADE NOTES 1. Backward Incompatible Changes ======================================== +- Core: + . The type of PHP_DEBUG and PHP_ZTS constants changed to bool. + - DOM: . New methods and constants were added to some DOM classes. If you inherit from these and you happen to have a method or property with the same name,