Skip to content

Commit 2c04455

Browse files
committed
Revert "Quickfix for FNSR issue"
This reverts commit 60c3118.
1 parent dc172ca commit 2c04455

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

src/Analyser/NodeScopeResolver.php

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -794,12 +794,11 @@ private function processStmtNode(
794794
$executionEnds = [];
795795
$methodImpurePoints = [];
796796
$statementResult = $this->processStmtNodesInternal($stmt, $stmt->stmts, $methodScope, $storage, static function (Node $node, Scope $scope) use ($nodeCallback, $methodScope, &$gatheredReturnStatements, &$gatheredYieldStatements, &$executionEnds, &$methodImpurePoints): void {
797+
$nodeCallback($node, $scope);
797798
if ($scope->getFunction() !== $methodScope->getFunction()) {
798-
$nodeCallback($node, $scope);
799799
return;
800800
}
801801
if ($scope->isInAnonymousFunction()) {
802-
$nodeCallback($node, $scope);
803802
return;
804803
}
805804
if ($node instanceof PropertyAssignNode) {
@@ -810,7 +809,6 @@ private function processStmtNode(
810809
&& $scope->getFunction()->getDeclaringClass()->getConstructor()->getName() === $scope->getFunction()->getName()
811810
&& TypeUtils::findThisType($scope->getType($node->getPropertyFetch()->var)) !== null
812811
) {
813-
$nodeCallback($node, $scope);
814812
return;
815813
}
816814
$methodImpurePoints[] = new ImpurePoint(
@@ -820,10 +818,8 @@ private function processStmtNode(
820818
'property assignment',
821819
true,
822820
);
823-
$nodeCallback($node, $scope);
824821
return;
825822
}
826-
$nodeCallback($node, $scope);
827823
if ($node instanceof ExecutionEndNode) {
828824
$executionEnds[] = $node;
829825
return;

0 commit comments

Comments
 (0)