xref: /PHP-7.4/Zend/tests/bug47836.phpt (revision dca18b68)
1--TEST--
2Bug #47836 (array operator [] inconsistency when the array has PHP_INT_MAX index value)
3--FILE--
4<?php
5
6$arr[PHP_INT_MAX] = 1;
7$arr[] = 2;
8
9var_dump($arr);
10?>
11--EXPECTF--
12Warning: Cannot add element to the array as the next element is already occupied in %s on line 4
13array(1) {
14  [%d]=>
15  int(1)
16}
17