Skip to content

[generator] ignore benevolence properly #553

New issue

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

Merged
merged 1 commit into from
Feb 4, 2025
Merged

[generator] ignore benevolence properly #553

merged 1 commit into from
Feb 4, 2025

Conversation

shish
Copy link
Collaborator

@shish shish commented Feb 4, 2025

functions which phpstan marked as __benevolent<foo|bar> were being type-hinted as foo|bar verbatim, when what we actually want to do is look inside the benevolent marker and check each type individually (which allows us to do things like stripping "false" from the return type when returning false becomes an exception and we never actually return false)

functions which phpstan marked as `__benevolent<foo|bar>` were being type-hinted as `foo|bar` verbatim, when what we actually want to do is look inside the `benevolent` marker and check each type individually (which allows us to do things like stripping "false" from the return type when returning false becomes an exception and we never actually return false)
@shish shish merged commit 58ebfd6 into master Feb 4, 2025
10 checks passed
@shish shish deleted the pr553 branch February 4, 2025 20:50
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.

1 participant