Description
The following code:
$oneDimensionalArray = [];
var_dump($oneDimensionalArray[0][1]);
var_dump($oneDimensionalArray[0][1] ?? '');
https://3v4l.org/1LMRe
Resulted in this output:
Warning: Undefined array key 0 in /in/1LMRe on line 4
Warning: Trying to access array offset on value of type null in /in/1LMRe on line 4
NULL
string(0) ""
But I expected this output instead:
Warning: Undefined array key 0 in /in/1LMRe on line 4
Warning: Trying to access array offset on value of type null in /in/1LMRe on line 4
NULL
Warning: Undefined array key 0 in /in/1LMRe on line 4
string(0) ""
PHP Version
8 - master
Operating System
any