false-positive error when read-only object is modified through php8.5 clone with · Issue #14838 · phpstan/phpstan · GitHub
Skip to content

false-positive error when read-only object is modified through php8.5 clone with #14838

Description

@JuliusJaenchen

Bug report

Image

Code snippet that reproduces the problem

https://phpstan.org/r/5b6c6845-aca3-4458-a7ba-03b14410d008

Expected output

The reported error:
Strict comparison using !== between null and null will always evaluate to false.
is reported incorrectly.

Expected output:
✅ (no errors)

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
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions