3v4l.org

run code in 300+ PHP versions simultaneously
<?php const FOO = 30; $foo = 5; $nested = 'nested'; switch ($foo) { case 10; case 20; echo $foo; break; case 'foo'; switch ($nested) { case 'nested' /*comment*/ ; break; default; break; } break; case FOO; { echo $foo; break; } default; echo 'default'; break; }
Output for git.master, git.master_jit
Deprecated: Case statements followed by a semicolon (;) are deprecated, use a colon (:) instead in /in/liFIK on line 7 Deprecated: Case statements followed by a semicolon (;) are deprecated, use a colon (:) instead in /in/liFIK on line 8 Deprecated: Case statements followed by a semicolon (;) are deprecated, use a colon (:) instead in /in/liFIK on line 11 Deprecated: Case statements followed by a semicolon (;) are deprecated, use a colon (:) instead in /in/liFIK on line 19 Deprecated: Case statements followed by a semicolon (;) are deprecated, use a colon (:) instead in /in/liFIK on line 13 default

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:
30.2 ms | 406 KiB | 5 Q