3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a1 = new stdclass; $a2 = new stdclass; $a3 = new stdclass; $a4 = new stdclass; $a5 = new stdclass; $a6 = new stdclass; $a7 = new stdclass; $a8 = new stdclass; $a9 = new stdclass; function bla($o){ return substr(spl_object_hash($o), 0, 16); } for($i = 1; $i < 10; $i++){ $var = ${'a' . $i}; var_dump($var); $r = hex2bin(bla($var)) ^ hex2bin(bla($a1)); $i = (int)bin2hex($r); $i += ($i % 2) === 0 ? 1 : -1; echo $i . "\n"; echo "-------------------\n"; }
Output for git.master, git.master_jit, rfc.property-hooks
object(stdClass)#1 (0) { } 1 ------------------- object(stdClass)#2 (0) { } 2 ------------------- object(stdClass)#3 (0) { } 3 ------------------- object(stdClass)#4 (0) { } 4 ------------------- object(stdClass)#5 (0) { } 5 ------------------- object(stdClass)#6 (0) { } 6 ------------------- object(stdClass)#7 (0) { } 7 ------------------- object(stdClass)#8 (0) { } 8 ------------------- object(stdClass)#9 (0) { } 9 -------------------

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