diff --git a/language/types/array.xml b/language/types/array.xml index c2a49b2836fd..5ecc93e8d368 100644 --- a/language/types/array.xml +++ b/language/types/array.xml @@ -533,12 +533,12 @@ var_dump($arr); - - As mentioned above, if no key is specified, the maximum of the existing - int indices is taken, and the new key will be that maximum - value plus 1 (but at least 0). If no int indices exist yet, the key will - be 0 (zero). - + + If no key is specified, the key will be the + maximum existing integer index + 1. If the array has no positive + integer indices, the key will be 0. + As of PHP 8.3.0, it can also be a negative integer. + Note that the maximum integer key used for this need not