Skip to content

Commit ee4ebab

Browse files
committed
[skip ci] Improve inheritance checked comment
zend_can_early_bind() might have already detected that the methods are incompatible. In that case the class is still early bound, but must compile error when inheritance is performed. Thus it is only safe to skip compatibility checks when zend_can_early_bind() has succeeded.
1 parent 5723fa2 commit ee4ebab

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

Zend/zend_inheritance.c

+2-3
Original file line numberDiff line numberDiff line change
@@ -1066,9 +1066,8 @@ static void perform_delayable_implementation_check(
10661066
}
10671067

10681068
/**
1069-
* @param check_only Set to false to throw compile errors on incompatible methods, or true to return
1070-
* INHERITANCE_ERROR.
1071-
* @param checked Whether the compatibility check has already been performed by zend_can_early_bind().
1069+
* @param check_only Set to false to throw compile errors on incompatible methods, or true to return INHERITANCE_ERROR.
1070+
* @param checked Whether the compatibility check has already succeeded in zend_can_early_bind().
10721071
*/
10731072
static zend_always_inline inheritance_status do_inheritance_check_on_method_ex(
10741073
zend_function *child, zend_class_entry *child_scope,

0 commit comments

Comments
 (0)