3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $obj = new stdClass; $obj->a = &$obj->b; $obj->b = 1; var_dump($obj);
Output for 5.0.0 - 5.6.28, 7.1.0
object(stdClass)#1 (2) { ["b"]=> &int(1) ["a"]=> &int(1) }
Output for 7.0.0 - 7.0.14
object(stdClass)#1 (2) { ["a"]=> &int(1) ["b"]=> &int(1) }
Output for 4.3.0 - 4.4.9
object(stdClass)(2) { ["b"]=> &int(1) ["a"]=> &int(1) }