Skip to content

Result of && is always false. #2870

@aivchen

Description

@aivchen

Bug report

PHPStan shouldn't report any errors in this case because it can't predict what rand() returns.

Code snippet that reproduces the problem

https://phpstan.org/r/e7652aad-b990-4aa7-8b6e-eeed31adc036

Expected output

No errors.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions