bmewburn / vscode-intelephense

PHP intellisense for Visual Studio Code
https://intelephense.com
Other
1.61k stars 94 forks source link

[1.11] False undefined variable error #2927

Closed eldair closed 3 months ago

eldair commented 3 months ago

Describe the bug Variable is falsely reported as undefined after a while statement.

To Reproduce

$a = true;
$b = 'asd';
$c = 1;

while ($a) {
    $c++;
    $a = $c < 10;
    $b .= $c;
}

return $b;

$b is reported as undefined in the last line.

Expected behavior No error reported

Screenshots image

Platform and version VScode on wsl 2/windows 11, intelephense v1.11

bmewburn commented 3 months ago

Thanks! Will be fixed in 1.11.2