3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $array[PHP_INT_MAX] = 42; $array[] = 43;
Output for 5.2.10 - 7.2.0
Warning: Cannot add element to the array as the next element is already occupied in /in/23ZLA on line 4
Output for 4.4.0 - 4.4.9, 5.0.5 - 5.2.9
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/23ZLA on line 3