-
-
Notifications
You must be signed in to change notification settings - Fork 946
Closed
phpstan/phpstan-src
#229Description
Bug report
We have a generic class, which receives exception class as templated parameter and then uses it to throw. Previously it was recognized by PhpStan, but both on 0.12.26 & 0.12.27 this now fails (both on throw and on @throws phpDoc).
Invalid type TExceptionClass of RuntimeException to throw
PHPDoc tag @throws with type TExceptionClass of Exception is not subtype of Throwable
Code snippet that reproduces the problem
https://phpstan.org/r/a2f79f88-a35e-450d-86d1-86d750e6b21b
Expected output
No error.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels