com php-src: Fix bug #71428: Zend/tests/bug71428.1.phpt Zend/tests/bug71428.3.phpt Zend/tests/bug72119.phpt Zend/zend_inheritance.c

From: Date: Thu, 05 May 2016 17:53:32 +0000
Subject: com php-src: Fix bug #71428: Zend/tests/bug71428.1.phpt Zend/tests/bug71428.3.phpt Zend/tests/bug72119.phpt Zend/zend_inheritance.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-92181@lists.php.net to get a copy of this message
Commit: 56c3d75780b7c2faf290722a615fd2d797d2f041 Author: Levi Morrison <levim@php.net> Thu, 5 May 2016 08:58:05 -0600 Parents: 9662259cb93ff04be80766bdade39d2e827e0e16 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=56c3d75780b7c2faf290722a615fd2d797d2f041 Log: Fix bug #71428 This also affects bug #72119 Bugs: https://bugs.php.net/71428 https://bugs.php.net/72119 Changed paths: M Zend/tests/bug71428.1.phpt M Zend/tests/bug71428.3.phpt M Zend/tests/bug72119.phpt M Zend/zend_inheritance.c Diff: diff --git a/Zend/tests/bug71428.1.phpt b/Zend/tests/bug71428.1.phpt index 064e8cf..e4d3a22 100644 --- a/Zend/tests/bug71428.1.phpt +++ b/Zend/tests/bug71428.1.phpt @@ -1,7 +1,5 @@ --TEST-- bug #71428.1: inheritance with null default values ---XFAIL-- -This is a BC break --FILE-- <?php class A { diff --git a/Zend/tests/bug71428.3.phpt b/Zend/tests/bug71428.3.phpt index 53e5129..558e87c 100644 --- a/Zend/tests/bug71428.3.phpt +++ b/Zend/tests/bug71428.3.phpt @@ -1,7 +1,5 @@ --TEST-- bug #71428: Validation type inheritance with = NULL ---XFAIL-- -This is a BC break --FILE-- <?php class A { } diff --git a/Zend/tests/bug72119.phpt b/Zend/tests/bug72119.phpt index eb9b4a7..064381a 100644 --- a/Zend/tests/bug72119.phpt +++ b/Zend/tests/bug72119.phpt @@ -14,6 +14,6 @@ class Hello implements Foo { } echo "OK\n"; ?> ---EXPECT-- -OK +--EXPECTF-- +Fatal error: Declaration of Hello::bar(array $baz = Array) must be compatible with Foo::bar(?array $baz = NULL) in %s on line %d diff --git a/Zend/zend_inheritance..c b/Zend/zend_inheritance.c index de9b63e..879e003 100644 --- a/Zend/zend_inheritance.c +++ b/Zend/zend_inheritance.c @@ -319,13 +319,11 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c return 0; } -#if 0 // This introduces BC break described at https://bugs.php.net/bug.php?id=72119 if (proto_arg_info->type_hint && proto_arg_info->allow_null && !fe_arg_info->allow_null) { /* incompatible nullability */ return 0; } -#endif /* by-ref constraints on arguments are invariant */ if (fe_arg_info->pass_by_reference != proto_arg_info->pass_by_reference) {

« previous php.cvs (#92181) next »