3v4l.org

run code in 300+ PHP versions simultaneously
<?php class ConstructorTest1 { public function __construct() { echo "ConstructorTest\n"; } } class ConstructorTest2 extends ConstructorTest { public function ConstructorTest1() { parent::__construct(); echo "ConstructorTest1\n"; } } class ConstructorTest3 extends ConstructorTest1 { public function ConstructorTest2() { $this->ConstructorTest1(); echo "ConstructorTest2\n"; } } class ConstructorTest4 extends ConstructorTest2 { public function ConstructorTest2() { parent::__construct(); echo "ConstructorTest3\n"; } } $test1 = new ConstructorTest1(); $test2 = new ConstructorTest2(); $test3 = new ConstructorTest3(); $test4 = new ConstructorTest4();
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Class "ConstructorTest" not found in /in/6oiqB:10 Stack trace: #0 {main} thrown in /in/6oiqB on line 10
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:
60.98 ms | 401 KiB | 8 Q