# Magic behaviour with __get, __set, __call and __callStatic is not exactly static analyser-friendly :) # Fortunately, You can ingore it by the following config. # rules: - PHPStan\Rules\Arrays\DeadForeachRule - PHPStan\Rules\Comparison\BooleanOrConstantConditionRule - PHPStan\Rules\Comparison\ElseIfConstantConditionRule - PHPStan\Rules\Comparison\IfConstantConditionRule - PHPStan\Rules\Comparison\TernaryOperatorConstantConditionRule parameters: bootstrap: "bootstrap.php" checkFunctionArgumentTypes: true checkArgumentsPassedByReference: true featureToggles: deadCatchesRule: false noopRule: false tooWideTypehints: false unreachableStatement: false ignoreErrors: - "#will always evaluate to false#" excludes_analyse: - %currentWorkingDirectory%/src/*/tests/* conditionalTags: PHPStan\Rules\Exceptions\DeadCatchRule: phpstan.rules.rule: %featureToggles.deadCatchesRule% PHPStan\Rules\DeadCode\NoopRule: phpstan.rules.rule: %featureToggles.noopRule% PHPStan\Rules\DeadCode\UnreachableStatementRule: phpstan.rules.rule: %featureToggles.unreachableStatement% PHPStan\Rules\TooWideTypehints\TooWideClosureReturnTypehintRule: phpstan.rules.rule: %featureToggles.tooWideTypehints% PHPStan\Rules\TooWideTypehints\TooWideFunctionReturnTypehintRule: phpstan.rules.rule: %featureToggles.tooWideTypehints% PHPStan\Rules\TooWideTypehints\TooWidePrivateMethodReturnTypehintRule: phpstan.rules.rule: %featureToggles.tooWideTypehints% services: - class: PHPStan\Rules\Classes\ImpossibleInstanceOfRule arguments: checkAlwaysTrueInstanceof: %checkAlwaysTrueInstanceof% tags: - phpstan.rules.rule - class: PHPStan\Rules\Comparison\ImpossibleCheckTypeFunctionCallRule arguments: checkAlwaysTrueCheckTypeFunctionCall: %checkAlwaysTrueCheckTypeFunctionCall% tags: - phpstan.rules.rule - class: PHPStan\Rules\Comparison\ImpossibleCheckTypeMethodCallRule arguments: checkAlwaysTrueCheckTypeFunctionCall: %checkAlwaysTrueCheckTypeFunctionCall% tags: - phpstan.rules.rule - class: PHPStan\Rules\Comparison\ImpossibleCheckTypeStaticMethodCallRule arguments: checkAlwaysTrueCheckTypeFunctionCall: %checkAlwaysTrueCheckTypeFunctionCall% tags: - phpstan.rules.rule - class: PHPStan\Rules\Comparison\StrictComparisonOfDifferentTypesRule arguments: checkAlwaysTrueStrictComparison: %checkAlwaysTrueStrictComparison% tags: - phpstan.rules.rule - class: PHPStan\Rules\Exceptions\DeadCatchRule - class: PHPStan\Rules\DeadCode\NoopRule - class: PHPStan\Rules\DeadCode\UnreachableStatementRule - class: PHPStan\Rules\TooWideTypehints\TooWideClosureReturnTypehintRule - class: PHPStan\Rules\TooWideTypehints\TooWideFunctionReturnTypehintRule - class: PHPStan\Rules\TooWideTypehints\TooWidePrivateMethodReturnTypehintRule