Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 2a44c50

Browse files
Fix
1 parent a9a2b60 commit 2a44c50

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/Analyser/MutatingScope.php‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3440,7 +3440,7 @@ public function unsetExpression(Expr $expr): self
34403440
new FuncCall(new FullyQualified('sizeof'), [new Arg($expr->var)]),
34413441
);
34423442

3443-
if ($expr->var instanceof Expr\ArrayDimFetch && $expr->var->dim !== null) {
3443+
if ($expr->var instanceof Expr\ArrayDimFetch && $expr->var->dim !== null && !$exprVarType->isIterableAtLeastOnce()->yes()) {
34443444
$varVar = $this->getType($expr->var->var);
34453445
$varDim = $this->getType($expr->var->dim);
34463446
$scope = $scope->specifyExpressionType(

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /