Skip to content
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

Report dead types even in multi-exception catch II #2399

Merged

Conversation

JanTvrdik
Copy link
Contributor

This is rewrite of #2067. The tests are the same, but the implementation is rewritten.

The first commit is pure refactoring to make it more obvious what is actually happening without altering the behavior. The second commit contains the new behavior.

@phpstan-bot
Copy link
Collaborator

You've opened the pull request against the latest branch 1.11.x. If your code is relevant on 1.10.x and you want it to be released sooner, please rebase your pull request and change its target to 1.10.x.

Verified

This commit was signed with the committer’s verified signature.
JanTvrdik Jan Tvrdík
@JanTvrdik JanTvrdik force-pushed the dead-type-in-multi-exception-catch branch from b99c367 to edc7469 Compare May 11, 2023 22:20
@JanTvrdik JanTvrdik changed the base branch from 1.11.x to 1.10.x May 11, 2023 22:20

Verified

This commit was signed with the committer’s verified signature.
JanTvrdik Jan Tvrdík
[closes phpstan/phpstan#7312]


Co-authored-by: Jan Nedbal <janedbal@gmail.com>
@JanTvrdik JanTvrdik force-pushed the dead-type-in-multi-exception-catch branch from edc7469 to cb2c5ae Compare May 11, 2023 22:27
@ondrejmirtes
Copy link
Member

Yeah, let's try this, thank you :)

@ondrejmirtes
Copy link
Member

FYI I did a small fix (phpstan/phpstan#9406) - look at https://phpstan.org/r/9daa180b-9405-4e98-9b33-075e5464cbc4 - if app2() isn't marked as dead catch, app() can't be either.

See the fix: c587dd1

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.

None yet

3 participants