Feature request
In some cases, I need to call private method of object (in my case it's happening in closure like friendly function in C++).
Code snippet that reproduces the problem
https://phpstan.org/r/75c0ce71-73d3-44f8-94a8-35ab1e083ff9 (sorry for long example, but it cannot be shown shorter)
Little description: It has Parameter that use Type. Link consist of two Parameters. In some cases, it needs to change type for two Parameters simultaneously without Link recreation, but it cannot be done due to Parameter validation (canChangeType method).
Call doChangeType method, catch error "Call to private method doChangeType of class Parameter.".
Propose
I propose to add scope PHPDoc tag that show current scope, because Phpstan don't consider bindTo second argument. Example in closure of __invoke method of ParameterTypeChangeMacroService.
Feature request
In some cases, I need to call private method of object (in my case it's happening in closure like friendly function in C++).
Code snippet that reproduces the problem
https://phpstan.org/r/75c0ce71-73d3-44f8-94a8-35ab1e083ff9 (sorry for long example, but it cannot be shown shorter)
Little description: It has
Parameterthat useType.Linkconsist of two Parameters. In some cases, it needs to change type for two Parameters simultaneously withoutLinkrecreation, but it cannot be done due toParametervalidation (canChangeTypemethod).Call
doChangeTypemethod, catch error "Call to private method doChangeType of class Parameter.".Propose
I propose to add
scopePHPDoc tag that show current scope, because Phpstan don't considerbindTosecond argument. Example in closure of__invokemethod ofParameterTypeChangeMacroService.