Skip to content

unset.possiblyHookedProperty is reported for properties annotated @final #12999

@lpd-au

Description

@lpd-au

Bug report

However, if the same property is only annotated as @final, an unset.possiblyHookedProperty error is reported. This makes it impossible to write code that passes phpstan under both PHP 8.3 and 8.4.

Code snippet that reproduces the problem

https://phpstan.org/r/c073c026-bbeb-43fa-b3ee-1907e2cc9d72

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

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions