From 9168d80f6a4a1f4a9756d196d382c2e271ebbac4 Mon Sep 17 00:00:00 2001 From: Daniel Scherzer Date: Thu, 17 Sep 2026 11:10:45 -0700 Subject: [PATCH] Remove unused INIT_CLASS_ENTRY_INIT_METHODS macro --- UPGRADING.INTERNALS | 3 +++ Zend/zend_API.h | 35 ----------------------------------- 2 files changed, 3 insertions(+), 35 deletions(-) diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS index 45c4ef34e852..efcf9c00544e 100644 --- a/UPGRADING.INTERNALS +++ b/UPGRADING.INTERNALS @@ -42,6 +42,9 @@ PHP 8.7 INTERNALS UPGRADE NOTES doing an assignment followed by GC_ADDREF(). - Added zend_call_method_if_exists_ex() which accepts named parameters and retrieving the callability failure error message. +- The INIT_CLASS_ENTRY_INIT_METHODS() macro, which was previously used as + part of handling disabled classes, was removed following the removal of + the `disable_classes` INI setting in PHP 8.5. ======================== 2. Build system changes diff --git a/Zend/zend_API.h b/Zend/zend_API.h index 425139e3a00b..900a622ae83a 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -289,41 +289,6 @@ typedef struct _zend_fcall_info_cache { class_container.info.internal.builtin_functions = functions; \ } -#define INIT_CLASS_ENTRY_INIT_METHODS(class_container, functions) \ - { \ - class_container.default_object_handlers = &std_object_handlers; \ - class_container.constructor = NULL; \ - class_container.destructor = NULL; \ - class_container.clone = NULL; \ - class_container.serialize = NULL; \ - class_container.unserialize = NULL; \ - class_container.create_object = NULL; \ - class_container.get_static_method = NULL; \ - class_container.__call = NULL; \ - class_container.__callstatic = NULL; \ - class_container.__tostring = NULL; \ - class_container.__get = NULL; \ - class_container.__set = NULL; \ - class_container.__unset = NULL; \ - class_container.__isset = NULL; \ - class_container.__debugInfo = NULL; \ - class_container.__serialize = NULL; \ - class_container.__unserialize = NULL; \ - class_container.parent = NULL; \ - class_container.num_interfaces = 0; \ - class_container.trait_names = NULL; \ - class_container.num_traits = 0; \ - class_container.trait_aliases = NULL; \ - class_container.trait_precedences = NULL; \ - class_container.interfaces = NULL; \ - class_container.get_iterator = NULL; \ - class_container.iterator_funcs_ptr = NULL; \ - class_container.arrayaccess_funcs_ptr = NULL; \ - class_container.info.internal.module = NULL; \ - class_container.info.internal.builtin_functions = functions; \ - } - - #define INIT_NS_CLASS_ENTRY(class_container, ns, class_name, functions) \ INIT_CLASS_ENTRY(class_container, ZEND_NS_NAME(ns, class_name), functions)