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
Report wrong type expected by an array_map closure #5356
Labels
Milestone
Comments
@ondrejmirtes After the latest commit in dev-master, PHPStan now reports different result with your code snippet: @@ @@
-PHP 7.4 – 8.0
+PHP 7.4 – 8.0 (1 error)
==========
-No errors
+6: Parameter #1 $callback of function array_map expects callable(string): mixed, Closure(array): 'a' given.
PHP 7.1 – 7.3 (3 errors)
========== Full reportPHP 7.4 – 8.0 (1 error)
PHP 7.1 – 7.3 (3 errors)
|
@ondrejmirtes After the latest commit in dev-master, PHPStan now reports different result with your code snippet: @@ @@
-No errors
+6: Parameter #1 $callback of function array_map expects callable(string): mixed, Closure(array): 'a' given. Full report
|
ondrejmirtes
added a commit
to phpstan/phpstan-src
that referenced
this issue
Sep 12, 2021
Closes phpstan/phpstan#5356 Closes phpstan/phpstan#1954
mglaman
pushed a commit
to mglaman/phpstan-src
that referenced
this issue
Oct 7, 2021
Closes phpstan/phpstan#5356 Closes phpstan/phpstan#1954
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. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Feature request
https://phpstan.org/r/2c752186-1a20-465a-9e94-0be9cb120669
https://phpstan.org/r/b9bc584a-db2a-46e3-8382-b6c69a4ff93e
The text was updated successfully, but these errors were encountered: