Skip to content

Commit e228b77

Browse files
committed
remove scome on post/pre incs
1 parent 17dca0e commit e228b77

1 file changed

Lines changed: 0 additions & 10 deletions

File tree

‎src/NodeTypeResolver/PHPStan/Scope/PHPStanNodeScopeResolver.php‎

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -226,14 +226,6 @@ private function fillScope(array $stmts, string $filePath, MutatingScope $scope)
226226
return;
227227
}
228228

229-
if ($node instanceof PostInc ||
230-
$node instanceof PostDec ||
231-
$node instanceof PreInc ||
232-
$node instanceof PreDec) {
233-
$node->var->setAttribute(AttributeKey::SCOPE, $mutatingScope);
234-
return;
235-
}
236-
237229
if ($node instanceof ArrayDimFetch) {
238230
$node->var->setAttribute(AttributeKey::SCOPE, $mutatingScope);
239231
if ($node->dim instanceof Expr) {
@@ -479,8 +471,6 @@ private function nodeScopeResolverProcessNodes(
479471
MutatingScope $mutatingScope,
480472
callable $nodeCallback
481473
): void {
482-
Assert::allIsInstanceOf($stmts, Stmt::class);
483-
484474
try {
485475
$this->nodeScopeResolver->processNodes($stmts, $mutatingScope, $nodeCallback);
486476
} catch (ParserErrorsException|ParserException|ShouldNotHappenException|UndefinedVariableException) {

0 commit comments

Comments
 (0)