On 12/09/2019 22:56, Andreas Hennings wrote:
$var[$k0][? $k1][? $k2]++;

This is great but the second "?" is redundant isn't it?


If the rule is "you cannot read a non-existent array element without ?" then no: $var[$k0][? $k1] allows you to read that element, and from context treat it as an array; but that array won't have a key $k2, so you also need to say that reading *that* was deliberate, and from context treat it as an integer.


Regards,

--
Rowan Tommins (né Collins)
[IMSoP]

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to