3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php error_reporting(~0); $a = array(array(), 1, (object) array(), INF); sort($a); print_r($a);
Output for 5.1.0 - 7.1.0
Notice: Object of class stdClass could not be converted to int in /in/LrP9O on line 4 Array ( [0] => stdClass Object ( ) [1] => 1 [2] => INF [3] => Array ( ) )
Output for 4.3.6 - 5.0.5
Array ( [0] => 1 [1] => INF [2] => stdClass Object ( ) [3] => Array ( ) )
Output for 4.3.0 - 4.3.5
Notice: Use of undefined constant INF - assumed 'INF' in /in/LrP9O on line 3 Array ( [0] => INF [1] => 1 [2] => stdClass Object ( ) [3] => Array ( ) )