xref: /php-src/Zend/tests/objects/objects_007.phpt (revision 275f63e7)
1--TEST--
2method overloading with different method signature
3--INI--
4error_reporting=8191
5--FILE--
6<?php
7
8class test {
9    function foo($arg, &$arg2 = NULL) {}
10}
11
12class test2 extends test {
13    function foo($arg, &$arg2 = NULL) {}
14}
15
16class test3 extends test {
17    function foo($arg, &$arg2) {}
18}
19
20?>
21--EXPECTF--
22Fatal error: Declaration of test3::foo($arg, &$arg2) must be compatible with test::foo($arg, &$arg2 = null) in %s on line %d
23