We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
It seems phpstan is "forgetting" the shape of an array by just adding 2 conditional statements.
https://phpstan.org/r/3412d834-a20f-4968-aeae-06b6b07e4463
Array shape is not forgotten.
1.8.5 caught some more issues to fix in our product!
The text was updated successfully, but these errors were encountered:
Too me it's a duplicate of #7963 and #8004
Since the array_shape is very complex, it is simplified by phpstan.
Sorry, something went wrong.
@bendavies After the latest push in 1.8.x, PHPStan now reports different result with your code snippet:
@@ @@ 5: Dumped type: int -10: Dumped type: int|string|null +10: Dumped type: int
Dumped type: int
Seems like it's solved by phpstan/phpstan-src@43d3652...bd57fc5
Do you want to add a regression test @ondrejmirtes @rvanvelzen ? (I can do it if the test if wanted)
phpstan/phpstan-src@10efc8b
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
No branches or pull requests
Bug report
It seems phpstan is "forgetting" the shape of an array by just adding 2 conditional statements.
Code snippet that reproduces the problem
https://phpstan.org/r/3412d834-a20f-4968-aeae-06b6b07e4463
Expected output
Array shape is not forgotten.
Did PHPStan help you today? Did it make you happy in any way?
1.8.5 caught some more issues to fix in our product!
The text was updated successfully, but these errors were encountered: