Skip to content

Conversation

staabm
Copy link
Contributor

@staabm staabm commented Sep 23, 2024

I now understood why my previous test was not failling and was able to apply the suggested fix

followup to #3421

Copy link
Contributor Author

@staabm staabm Sep 23, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the test in the above if (line 52) is still not able to narrow the type, but I think its related to that we compare 2 variables.

when comparing against literals - as we do in the new test - we at least were able to trigger the bug in the previous StaticTypeFactory::falsey()->equals($this->subtractedType) logic

@ondrejmirtes ondrejmirtes merged commit 9f13233 into phpstan:1.12.x Sep 26, 2024
482 of 499 checks passed
@ondrejmirtes
Copy link
Member

Thank you!

@staabm staabm deleted the more-then-falsy branch September 26, 2024 07:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants