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
I can't reproduce this issue on https://phpstan.org/try, is the rule overwriteVariablesWithLoop set to true there?
If I use foreach twice I got error on second run Foreach overwrites $var with its value variable. But $var is local variable here so it shouldn't be reported imho.
foreach ($variable as $var) {
// do something
}
foreach ($variable as $var) {
// do something else
}
The text was updated successfully, but these errors were encountered:
I can't reproduce this issue on https://phpstan.org/try, is the rule
overwriteVariablesWithLoop
set totrue
there?If I use foreach twice I got error on second run
Foreach overwrites $var with its value variable.
But $var is local variable here so it shouldn't be reported imho.The text was updated successfully, but these errors were encountered: