phpstan-src icon indicating copy to clipboard operation
phpstan-src copied to clipboard

phpstorm.meta.php support for dynamic return types

Open DCoderLT opened this issue 3 years ago • 0 comments

This PR starts to add support for PHPStorm’s metadata files. It only supports a few basic directives for resolving method/function return types, but of course support for other directives can be added.

I do not think this is ready for a merge yet, I would like some feedback before I dig deeper into it. For example:

  • which other meta directives need to be supported (registerArgumentsSet)?
  • what tests are needed?
  • PHPStorm scans the entire project looking for these meta files, including vendor directories. Should PHPStan also look for vendored meta files by default? I’m a bit concerned about parsing time for large projects.

DCoderLT avatar Feb 04 '23 11:02 DCoderLT