3v4l.org

run code in 300+ PHP versions simultaneously
<?php abstract class class1 { abstract public function method1($arg1); public function method2($arg1) { var_dump(func_get_args()); } } class class2 extends class1 { public function method1($arg1) { var_dump(func_get_args()); } public function method2($arg1, $arg2) { var_dump(func_get_args()); } } $obj = new class2; $obj->method1(); $obj->method2();
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Declaration of class2::method2($arg1, $arg2) must be compatible with class1::method2($arg1) in /in/9nNHG on line 19
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
41.06 ms | 401 KiB | 8 Q