Skip to content

Union Type with match (true) causes wrong type assumption. #7721

@Dgame

Description

@Dgame

Bug report

Maybe related to #7698: Union Type with match (true) causes wrong type assumption.

Code snippet that reproduces the problem

https://phpstan.org/r/f5296bb1-399d-48ee-92c1-0c1ae8eb6e45

Expected output

No error

Did PHPStan help you today? Did it make you happy in any way?

Of course it does 👍

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions