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
It would be awesome, if there is nullability check in other method, to recognise that variable can not be null anymore.
https://phpstan.org/r/4e1685f6643e62a6eb8ed7c9fb31d482
/** @var null|string */ private $a; public function hasA(): bool { return $this->a !== null; } public function getA(): string { if (false === $this->hasA()) { throw new \LogicException(); } return $this->a; }
I expected no errors as it seems to be valid PHP code to me.
The text was updated successfully, but these errors were encountered:
This has been discussed many times 😊
See #534, #634, #201.
Sorry, something went wrong.
No branches or pull requests
Summary of a problem or a feature request
It would be awesome, if there is nullability check in other method, to recognise that variable can not be null anymore.
Code snippet that reproduces the problem
https://phpstan.org/r/4e1685f6643e62a6eb8ed7c9fb31d482
Expected output
I expected no errors as it seems to be valid PHP code to me.
The text was updated successfully, but these errors were encountered: