phpstan: PHPStan fails to fallback to plain PHPDoc annotation when erroring in Psalm specific annotation
Bug report
The callable-string type is not supported by PHPStan, but it is by Psalm. When the first tries to read the annotation, I think that some internal error happens and an error stating that the parameter has no value type specified is reported. Since there is a plain @param annotation above, I would at least expect PHPStan to fallback to read it. I’m not sure about how much difficult it would be to implement support for callable-string, but if you can give me some advice I may try to open a PR
Code snippet that reproduces the problem
https://phpstan.org/r/ef4e5af0-13a4-4524-a45c-e3ddacef140c
Expected output
No error should be reported
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 16 (15 by maintainers)
Type aliases are now supported thanks to https://github.com/phpstan/phpstan-src/pull/460 but this issue still remains.