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
Unexpected problem reported for the SplTempFileObject::fstat() method #5404
Comments
This bug report is missing a link to reproduction on phpstan.org. It will most likely be closed after manual review. |
Please follow this issue template: https://github.com/phpstan/phpstan/issues/new?assignees=&labels=&template=Function_signature_mismatch.md
Thanks. |
@Kolyunya After the latest commit in dev-master, PHPStan now reports different result with your code snippet: @@ @@
-5: Cannot access offset 'size' on array(0 => int, 1 => int, 2 => int, 3 => int, 4 => int, 5 => int, 6 => int, 7 => int, ...)|false.
+5: Cannot access offset 'size' on array{0: int, 1: int, 2: int, 3: int, 4: int, 5: int, 6: int, 7: int, ...}|false. Full report
|
@Kolyunya After the latest commit in dev-master, PHPStan now reports different result with your code snippet: @@ @@
-5: Cannot access offset 'size' on array(0 => int, 1 => int, 2 => int, 3 => int, 4 => int, 5 => int, 6 => int, 7 => int, ...)|false.
+No errors |
Fixed by: phpstan/phpstan-src#996 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Bug report
Code snippet that reproduces the problem
https://phpstan.org/r/db3231ce-001d-4349-b052-b3eb5eec046e
Expected output
According to the docs
fstat()
returnsarray
, notarray|false
.Also according to the docs the array has a
size
key.So, no problems are expected to be reported.
Actual output
Did PHPStan help you today? Did it make you happy in any way?
PHPStan helps me every day a ton. The best tool in my toolbox.
The text was updated successfully, but these errors were encountered: