3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php interface Interface1 { public function test1 (array $arr1 = [], array &$arr2 = []); } interface Interface2 extends Interface1 { public function test1 (array $arr1 = []); }
based on 0Q4Mo
Output for 7.0.0 - 7.2.12
Fatal error: Declaration of Interface2::test1(array $arr1 = Array) must be compatible with Interface1::test1(array $arr1 = Array, array &$arr2 = Array) in /in/juZTe on line 7
Process exited with code 255.
Output for hhvm-3.22.0
Fatal error: Uncaught Error: Declaration of Interface2::test1() must be compatible with that of Interface1::test1() in /in/juZTe:-1 Stack trace: #0 {main}
Process exited with code 255.
Output for hhvm-3.15.4 - 3.21.3
Fatal error: Uncaught Error: Declaration of Interface2::test1() must be compatible with that of Interface1::test1() in /in/juZTe:7 Stack trace: #0 {main}
Process exited with code 255.
Output for 5.6.0 - 5.6.38
Fatal error: Declaration of Interface2::test1() must be compatible with Interface1::test1(array $arr1 = Array, array &$arr2 = Array) in /in/juZTe on line 7
Process exited with code 255.