Bug report
When a rule is hooked on parent of those nodes, e.g. like this:
public function getNodeType(): string
{
return Node::class; // or CallLike or any other common parent
}
and analyses this simple code
The rule is called twice:
- Once with MethodCall node from here
- Once with NullsafeMethodCall node from here
Code snippet that reproduces the problem
https://phpstan.org/r/2aa36241-7795-4561-bf14-5c8d641f89fb
Expected output
Visit node only once.
Did PHPStan help you today? Did it make you happy in any way?
No response