You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
PHPStan insists a use variable by reference cannot change types #7751
When writing a Closure with a use reference variable, PHPStan assumes the Type of that variable is always what it was at the place where the code is written.
Activity
ondrejmirtes commentedon Aug 6, 2022
References are tricky for static analysis. Use this workaround: https://phpstan.org/r/d0a6e763-62c0-42f2-a99f-6817809609bd
github-actions commentedon Oct 29, 2026
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.