Skip to content

Do not report invariant template type mismatch when both type arguments are the same template parameter narrowed by control flow#5921

Merged
ondrejmirtes merged 1 commit into
phpstan:2.2.xfrom
rvanvelzen:bug-13190
Jun 23, 2026
Merged

Do not report invariant template type mismatch when both type arguments are the same template parameter narrowed by control flow#5921
ondrejmirtes merged 1 commit into
phpstan:2.2.xfrom
rvanvelzen:bug-13190

Conversation

@rvanvelzen

Copy link
Copy Markdown
Contributor

…ts are the same template parameter narrowed by control flow

Closes phpstan/phpstan#13190
@ondrejmirtes

Copy link
Copy Markdown
Member

Welcome back @rvanvelzen! I always love your PRs, they're an insta-merge for me 😊 Thank you.

@ondrejmirtes ondrejmirtes merged commit 302796a into phpstan:2.2.x Jun 23, 2026
668 of 671 checks passed
@rvanvelzen rvanvelzen deleted the bug-13190 branch June 24, 2026 13: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.

asserting Foo<T>|T is Foo should result in Foo<T>|Foo not Foo<T>

2 participants