3v4l.org

run code in 300+ PHP versions simultaneously
<?php function VS($x, $y) { var_dump($x === $y); if ($x !== $y) { echo "Failed: $y\n"; echo "Got: $x\n"; var_dump(debug_backtrace()); } } function VERIFY($x) { VS($x != false, true); } ////////////////////////////////////////////////////////////////////// $valid_res = imagecreate(10, 10); $invalid_res = imagecreate(10, 10); imagedestroy($invalid_res); VERIFY(!is_object(null)); VERIFY(!is_object(123)); VERIFY(!is_object("test")); VERIFY(!is_object(array(123))); VERIFY(is_object(new stdclass)); VERIFY(!is_object($valid_res)); VERIFY(!is_object($invalid_res)); { $v = unserialize("O:8:\"stdClass\":1:{s:4:\"name\";s:5:\"value\";}"); VERIFY(is_object($v)); } { $v = unserialize("O:8:\"stdClass\":1:{s:7:\"\0*\0name\";s:5:\"value\";}"); VERIFY(is_object($v)); }
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Call to undefined function imagecreate() in /in/GHcR8:12 Stack trace: #0 {main} thrown in /in/GHcR8 on line 12
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:
53.42 ms | 401 KiB | 8 Q