Skip to content

@phpstan-assert tags are not correctly implicitly inherited #10037

@ondrejmirtes

Description

@ondrejmirtes

Bug report

See the example. It works only if the assert tag is repeated in PostFetcher.

Code snippet that reproduces the problem

https://phpstan.org/r/fb8735dc-026d-40ea-a724-c2e7eef04a9a

Expected output

Correct type in the truthy if branch.

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

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions