3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $arr = array(); $arr[PHP_INT_MAX] = null; $arr[] = null; var_dump($arr);
based on 2Fjl4
Output for 5.2.10 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
Warning: Cannot add element to the array as the next element is already occupied in /in/Nm4GZ on line 4 array(1) { [9223372036854775807]=> NULL }
Output for 4.4.0 - 4.4.9, 5.0.5 - 5.2.9
array(2) { [9223372036854775807]=> NULL [-9223372036854775808]=> NULL }
Output for 4.3.0 - 4.3.11, 5.0.0 - 5.0.4
Notice: Use of undefined constant PHP_INT_MAX - assumed 'PHP_INT_MAX' in /in/Nm4GZ on line 3 array(2) { ["PHP_INT_MAX"]=> NULL [0]=> NULL }