Merge branch 'PHP-7.4'

* PHP-7.4:
  Fixed bug 78175 (Preloading must store default values of static variables and properties)
This commit is contained in:
Dmitry Stogov 2019-06-24 20:34:05 +03:00
commit e18c60cd8d
11 changed files with 127 additions and 16 deletions

View file

@ -1151,7 +1151,7 @@ ZEND_API void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent
} while (dst != end);
} else if (ce->type == ZEND_USER_CLASS) {
if (CE_STATIC_MEMBERS(parent_ce) == NULL) {
ZEND_ASSERT(parent_ce->ce_flags & ZEND_ACC_IMMUTABLE);
ZEND_ASSERT(parent_ce->ce_flags & (ZEND_ACC_IMMUTABLE|ZEND_ACC_PRELOADED));
zend_class_init_statics(parent_ce);
}
src = CE_STATIC_MEMBERS(parent_ce) + parent_ce->default_static_members_count;