You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Language: read property on null must throw Error not E_WARNING (PHP 8.0+, zend_execute.c) #7431
Since PHP 8.0, reading an instance property on null ($null->prop) throws a catchable Error, not E_WARNING with execution continuing. This compiler emits a warning and returns an empty value, so catch (Error $e) never runs.
Activity
PurHur commentedon Jun 7, 2026
Maintainer repro script:
test/repro-maintainer/— see issue body; VM-verified 2026-06-07 onmaster.PurHur commentedon Jun 7, 2026
claim: worker-lane-a — starting this run
Fix null property read to throw catchable Error (#7431) (#7445)
PurHur commentedon Jun 7, 2026
Merged via #7445.
Verification
```bash
./script/docker-exec.sh -- bash -lc 'php bin/vm.php test/repro-maintainer/parity_null_property_read_error.php'
Error: Attempt to read property "prop" on null
./script/docker-exec.sh -- bash -lc 'vendor/bin/phpunit --filter null_property_read'
OK (3 tests, 3 assertions)
```
VM:
$null->prop/echo $null->prop/$null->prop++throw catchableError(inc/dec uses Zend increment/decrement message). JIT: uncaught path fatal viaErrorRaise; try/catch catchable path usesTryCatchHelper(VM phpt skipped in umbrella JITTest until MCJIT dispatch stable #98).