Bug report
Upgrading from 2.1.16 to 2.1.17 facile-it/paraunit#318
I get a regression where DOMElement::$attributes is considered nullable, where it's not. Proof: https://www.php.net/manual/en/class.domnode.php#domnode.props.attributes
The property is nullable for its ancestor (\DOMNode), but not in this case.
Code snippet that reproduces the problem
https://phpstan.org/r/ce94a684-3de4-4a48-9441-b5586c967fac
Expected output
No errors, since it shouldn't be nullable.
Did PHPStan help you today? Did it make you happy in any way?
Totally! So many bug catched early!