3v4l.org

run code in 300+ PHP versions simultaneously
<?php class MyClass { public function test() {echo __METHOD__ . "\n";} public static function testStatic() {echo __METHOD__ . "\n";} } class MyClass2 { public function test() {echo __METHOD__ . "\n"; call_user_func('parent::test'); } public static function testStatic() {echo __METHOD__ . "\n"; call_user_func('parent::testStatic'); call_user_func('static::testLate');} } class MyClass3 { public static function testLate() {echo __METHOD__ . "\n";} } echo "call object method:\n"; $o = new MyClass3(); $o->test(); $o->testStatic(); echo "call static method:\n"; MyClass3::testStatic();
Output for git.master, git.master_jit, rfc.property-hooks
call object method: Fatal error: Uncaught Error: Call to undefined method MyClass3::test() in /in/Cv2oc:19 Stack trace: #0 {main} thrown in /in/Cv2oc 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:
52.73 ms | 401 KiB | 8 Q