We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
https://psalm.dev/r/dfdf721e08
Since baz is originally declared on FooBar, Bar can access Foo::baz.
baz
FooBar
Bar
Foo::baz
The text was updated successfully, but these errors were encountered:
I found these snippets:
<?php class FooBar { protected function baz(FooBar $other): void {} } class Foo extends FooBar { protected function baz(FooBar $other): void {} } class Bar extends FooBar { protected function baz(FooBar $other): void { if ($other instanceof Foo) { $other->baz($this); } } }
Psalm output (using commit a469c82): ERROR: InaccessibleMethod - 18:21 - Cannot access protected method Foo::baz from context Bar
Sorry, something went wrong.
Check oldest ancestor for protected method visibility (fixes vimeo#5595)
78049ae
870c433
No branches or pull requests
https://psalm.dev/r/dfdf721e08
Since
baz
is originally declared onFooBar
,Bar
can accessFoo::baz
.The text was updated successfully, but these errors were encountered: