summaryrefslogtreecommitdiff
path: root/Zend/zend_inheritance.c
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2019-03-27 18:11:00 +0100
committerNikita Popov <nikita.ppv@gmail.com>2019-03-27 18:11:00 +0100
commit73a59eff52e92b1c8ede73df3de3eb602f65f14f (patch)
tree0be5cad110a38969a2a65ca2cae8cc5d241bc35d /Zend/zend_inheritance.c
parent6d71d983dac4557653f935efebdff843d5bea891 (diff)
parent058554810649da431efa3ab851be17b0d2f96fb8 (diff)
downloadphp-git-73a59eff52e92b1c8ede73df3de3eb602f65f14f.tar.gz
Merge branch 'PHP-7.4'
Diffstat (limited to 'Zend/zend_inheritance.c')
-rw-r--r--Zend/zend_inheritance.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Zend/zend_inheritance.c b/Zend/zend_inheritance.c
index 9626434f05..a4e437f271 100644
--- a/Zend/zend_inheritance.c
+++ b/Zend/zend_inheritance.c
@@ -597,11 +597,11 @@ static void do_inheritance_check_on_method(zend_function *child, zend_function *
proto = parent;
}
} else if (proto) {
- if (proto->common.scope->ce_flags & ZEND_ACC_INTERFACE) {
- /* ctors only have a prototype if it comes from an interface */
- /* and if that is the case, we want to check inheritance against it */
+ /* ctors only have a prototype if is abstract (or comes from an interface) */
+ /* and if that is the case, we want to check inheritance against it */
+ if (proto->common.fn_flags & ZEND_ACC_ABSTRACT) {
parent = proto;
- } else if (!(proto->common.fn_flags & ZEND_ACC_ABSTRACT)) {
+ } else {
break;
}
} else {