mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Merge branch 'PHP-7.4'
* PHP-7.4: Fixed bug #77613 (method visibility change) (reverted ZEND_ACC_CTOR and ZEND_ACC_DTOR flags removal)
This commit is contained in:
commit
4474cf43e6
7 changed files with 38 additions and 9 deletions
|
@ -2314,11 +2314,13 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio
|
|||
scope->__isset = __isset;
|
||||
scope->__debugInfo = __debugInfo;
|
||||
if (ctor) {
|
||||
ctor->common.fn_flags |= ZEND_ACC_CTOR;
|
||||
if (ctor->common.fn_flags & ZEND_ACC_STATIC) {
|
||||
zend_error(error_type, "Constructor %s::%s() cannot be static", ZSTR_VAL(scope->name), ZSTR_VAL(ctor->common.function_name));
|
||||
}
|
||||
}
|
||||
if (dtor) {
|
||||
dtor->common.fn_flags |= ZEND_ACC_DTOR;
|
||||
if (dtor->common.fn_flags & ZEND_ACC_STATIC) {
|
||||
zend_error(error_type, "Destructor %s::%s() cannot be static", ZSTR_VAL(scope->name), ZSTR_VAL(dtor->common.function_name));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue