-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dev: replace type mixed
with more specific types
#6310
Comments
mixed
with more specific types
I think we should, in part, allow explicit However, for those annotated as |
@paulbalandan What's you say is correct, but I think it is difficult to do. Currently, there are too many |
You're right. It will be a pain to track all existing uses of |
I already sent few PR, review please. |
Is it really important to use Docbook or do I need to add a clarification |
@neznaika0 This issue is about Basically, we cannot change the method signature if the method can be overridden (by a user). |
|
Hello, I'm curious about how to display PHPStan errors for mixed types. I've attempted to run the following but there's no error.
However, I can find several
|
@paolooo Explicit
But
|
Thank you, @kenjis, for providing clarification. |
Type
mixed
meansobject|resource|array|string|int|float|bool|null
.https://www.php.net/manual/en/language.types.declarations.php#language.types.declarations.mixed
The current code base has a lot of type
mixed
in PHPDocs,But I think all of them are not correct.
And
mixed
prevents PHPStan level from increasing.We need to replace type
mixed
with more specific types.The text was updated successfully, but these errors were encountered: