We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
if (rand(0, 1)) { $a = 'b'; } if (rand(0, 1)) { $c = ['b' => 'everything is fine']; } if (isset($a, $c, $c[$a])) { echo $c[$a]; }
Variable $a might not be defined.
https://phpstan.org/r/718a84cf-24ba-449d-b364-d8c20bc8e7ed
Expected no errors
if done with two different issets works as expected (https://phpstan.org/r/7d472ba3-ec9e-4f08-8566-bccebced30bb)
The text was updated successfully, but these errors were encountered:
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.
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
Bug report
Variable $a might not be defined.
https://phpstan.org/r/718a84cf-24ba-449d-b364-d8c20bc8e7ed
Expected output
Expected no errors
if done with two different issets works as expected (https://phpstan.org/r/7d472ba3-ec9e-4f08-8566-bccebced30bb)
The text was updated successfully, but these errors were encountered: