mirror of
https://github.com/php/php-src.git
synced 2026-04-23 16:08:35 +02:00
Disallow abstract privae methods
This commit is contained in:
@@ -418,6 +418,9 @@ void zend_do_abstract_method(znode *function_name, znode *modifiers, znode *body
|
||||
}
|
||||
|
||||
if (modifiers->u.constant.value.lval & ZEND_ACC_ABSTRACT) {
|
||||
if(modifiers->u.constant.value.lval & ZEND_ACC_PRIVATE) {
|
||||
zend_error(E_COMPILE_ERROR, "%s function %s::%s() cannot be declared private", method_type, CG(active_class_entry)->name, function_name->u.constant.value.str.val);
|
||||
}
|
||||
if (body->u.constant.value.lval == ZEND_ACC_ABSTRACT) {
|
||||
zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user