Skip to content

Commit 46e986c

Browse files
committed
setup Expr
1 parent 0b8cb54 commit 46e986c

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

rules/DeadCode/PhpDoc/DeadVarTagValueNodeAnalyzer.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,12 @@ public function isDead(VarTagValueNode $varTagValueNode, Property|ClassConst|Exp
4040
return false;
4141
}
4242

43+
/** @var Expr $targetNode */
4344
$targetNode = $node instanceof Expression
4445
? $node->expr
4546
: $node->type;
4647

4748
if ($node instanceof Expression) {
48-
if (! $targetNode instanceof Expr) {
49-
return false;
50-
}
51-
5249
$varType = $this->nodeTypeResolver->getType($targetNode);
5350
$nativeType = $this->nodeTypeResolver->getNativeType($targetNode);
5451

0 commit comments

Comments
 (0)