Fixed issues

This commit is contained in:
Dmitry Stogov 2018-09-10 11:55:07 +03:00
parent 1d37e3a40e
commit 62d1871430
4 changed files with 5 additions and 7 deletions

View file

@ -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).
========================

View file

@ -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;

View file

@ -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 ??? | | | */

View file

@ -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) {