diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS index 2a5cf1b4931..b9126ed3879 100644 --- a/UPGRADING.INTERNALS +++ b/UPGRADING.INTERNALS @@ -29,9 +29,8 @@ PHP 7.4 INTERNALS UPGRADE NOTES (func->commpon.scope->constructor == func). - ZEND_ACC_IMPLEMENTED_ABSTRACT is removed (it was used only internally during inheritance). - - ZEND_ACC_IMPLEMENTED_ABSTRACT is removed (it was used only internally - ZEND_ACC_SHADOW property flag is removed. Instead of creating shadow - clone, now we use the same private propert_info, and should also + clone, now we use the same private property_info, and should also check property_info->ce (in the same way as with methods). ======================== diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index fdd138ccef9..88c24ba8aeb 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1100,8 +1100,7 @@ static void add_class_vars(zend_class_entry *scope, zend_class_entry *ce, int st if (((prop_info->flags & ZEND_ACC_PROTECTED) && !zend_check_protected(prop_info->ce, scope)) || ((prop_info->flags & ZEND_ACC_PRIVATE) && - prop_info->ce != scope && - (ce != scope || prop_info->ce != ce))) { + prop_info->ce != scope)) { continue; } prop = NULL; diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 2cef6b25cac..ba4550579ea 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -212,7 +212,7 @@ typedef struct _zend_oparray_context { #define ZEND_ACC_PROTECTED (1 << 9) /* | X | X | X */ #define ZEND_ACC_PRIVATE (1 << 10) /* | X | X | X */ /* | | | */ -/* TODO: explain the name ??? | | | */ +/* Property or method overrides private one | | | */ #define ZEND_ACC_CHANGED (1 << 11) /* | X | X | */ /* | | | */ /* TODO: used only by ext/reflection ??? | | | */ diff --git a/Zend/zend_object_handlers.c b/Zend/zend_object_handlers.c index 61d766c6a52..92524a86047 100644 --- a/Zend/zend_object_handlers.c +++ b/Zend/zend_object_handlers.c @@ -383,7 +383,7 @@ static zend_always_inline uintptr_t zend_get_property_offset(zend_class_entry *c if (flags & ZEND_ACC_PUBLIC) { check_changed: - if (UNEXPECTED(!(flags & ZEND_ACC_CHANGED))) { + if (!(flags & ZEND_ACC_CHANGED)) { no_changed: if (UNEXPECTED((flags & ZEND_ACC_STATIC) != 0)) { if (!silent) { @@ -491,7 +491,7 @@ ZEND_API zend_property_info *zend_get_property_info(zend_class_entry *ce, zend_s if (flags & ZEND_ACC_PUBLIC) { check_changed: - if (UNEXPECTED(!(flags & ZEND_ACC_CHANGED))) { + if (!(flags & ZEND_ACC_CHANGED)) { no_changed: if (UNEXPECTED((flags & ZEND_ACC_STATIC) != 0)) { if (!silent) {