-
-
Notifications
You must be signed in to change notification settings - Fork 946
Closed
phpstan/phpstan-src
#4157Closed
Copy link
Labels
Milestone
Description
Bug report
I have 2 equivalent classes. one is using promoted properties, while the other one uses regular properties.
only in one of the classes we get a generics error:
Template type Value is declared as covariant, but occurs in invariant position in property LanguageProperty2::$value.
Code snippet that reproduces the problem
https://phpstan.org/r/0c390d54-fa09-47bf-a062-33c7675c515c
Expected output
I am not sure, but I feel the 2 code examples should trigger the same errors..?
Did PHPStan help you today? Did it make you happy in any way?
No response
Reactions are currently unavailable