-
-
Notifications
You must be signed in to change notification settings - Fork 947
Tiny fake positive: early exception is not taken in account #4709
Copy link
Copy link
Closed
Description
Hi @ondrejmirtes 👋
I hope you are doing well 🐥
Bug report
I guess it's quite complicated to handle for stan, but this code cannot lead to null variables.
Code snippet that reproduces the problem
I thought the fake positive was happening because of the cast to int, making it hard for phpstan to acknowledge null values throw exceptions. But actually it's the same with an is_null method: https://phpstan.org/r/1a0ff9f2-ac6e-467e-89dc-ee21ca721962
Expected output
No warning raised. Both properties can only be int.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels