phpstan-src
phpstan-src copied to clipboard
PHPStan's source code. This is where development happens. Check https://github.com/phpstan/phpstan for the distribution repository.
trying a minimal approach to see whether the idea works as a whole --- for expression like `if (doFoo() > 0)` we want to pass the context specific return-type information...
closes https://github.com/phpstan/phpstan/issues/11928
Fixes https://github.com/phpstan/phpstan/issues/11906
Addresses https://github.com/phpstan/phpstan/issues/7520
[Motivation](https://phpstan.org/r/f7af5ab7-b201-4ddf-9080-ffbef44a4ce4): I refactored code to use `BcMath\Number` instead of `float`, and I didn't notice a printf usage with `%f`, which lead to incorrect result. PHPStan didn't complain, because `BcMath\Number` has...
fixes https://github.com/phpstan/phpstan/issues/8886
This will allow the `$this` or `static` in PHPDoc return type to be first replaced with final-overriden ObjectType before being thrown into `TypehintHelper::decideType()`.
refs https://github.com/phpstan/phpstan-src/pull/3885#pullrequestreview-2694393342, https://github.com/phpstan/phpstan-src/pull/3886#issuecomment-2735632469
closes https://github.com/phpstan/phpstan/issues/7804
Following the [discussion](https://github.com/phpstan/phpstan/discussions/11306) I created, this is my attempt at adding a command line option for ignoring new errors to trim down the baseline file. This enables the following workflow:...