Skip to content

Commit

Permalink
Fix bad merge into master
Browse files Browse the repository at this point in the history
This should only have been reverted in 7.0, but not for 7.1. (merge=ours??)
Added appropriate NEWS entry.
  • Loading branch information
bwoebi committed Apr 28, 2016
1 parent 357ee43 commit 2c8e4ba
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 9 deletions.
1 change: 1 addition & 0 deletions NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ PHP NEWS
. Fixed bug #62814 (It is possible to stiffen child class members visibility).
(Nikita)
. Fixed bug #69989 (Generators don't participate in cycle GC). (Nikita)
. Fixed bug #71428 (Inheritance and allow_null). (Joe)
. Fixed bug #71572 (String offset assignment from an empty string inserts
null byte). (Francois)
. Implemented the RFC `Support Class Constant Visibility`. (Sean DuBois,
Expand Down
2 changes: 0 additions & 2 deletions Zend/tests/bug71428.1.phpt
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
--TEST--
bug #71428.1: inheritance with null default values
--XFAIL--
This is a BC break
--FILE--
<?php
class A {
Expand Down
2 changes: 0 additions & 2 deletions Zend/tests/bug71428.3.phpt
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
--TEST--
bug #71428: Validation type inheritance with = NULL
--XFAIL--
This is a BC break
--FILE--
<?php
class A { }
Expand Down
4 changes: 2 additions & 2 deletions Zend/tests/bug72119.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ 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
3 changes: 0 additions & 3 deletions Zend/zend_inheritance.c
Original file line number Diff line number Diff line change
Expand Up @@ -319,13 +319,10 @@ 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) {
Expand Down

0 comments on commit 2c8e4ba

Please sign in to comment.