Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,12 @@ private function composeScope(
if ($leftTruthyTypes === null || $leftFalseyTypes === null) {
return null;
}
$leftTruthyScope = $scope->applySpecifiedTypes($leftTruthyTypes->setRootExpr($identical));
$leftFalseyScope = $scope->applySpecifiedTypes($leftFalseyTypes->setRootExpr($identical));
$rightTruthyTypes = $rightTypes($leftFalseyScope, TypeSpecifierContext::createTruthy());
if ($rightTruthyTypes === null) {
return null;
}
$leftTruthyScope = $scope->applySpecifiedTypes($leftTruthyTypes->setRootExpr($identical));
$rightTruthyScope = $leftFalseyScope->applySpecifiedTypes($rightTruthyTypes->setRootExpr($isObjectCall));

$types = $this->booleanNarrowingHelper->specifyDisjunction(
Expand Down
2 changes: 1 addition & 1 deletion src/Turbo/TurboExtensionEnabler.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
final class TurboExtensionEnabler
{

public const EXPECTED_EXTENSION_VERSION = '80f2bb1';
public const EXPECTED_EXTENSION_VERSION = '536f37b';

private static bool $active = false;

Expand Down
4 changes: 2 additions & 2 deletions turbo-ext/src/ForeachEmptyOrObjectNarrowingHelper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -317,13 +317,13 @@ class ForeachEmptyOrObjectNarrowingHelper
zv::Val leftFalseyTypes = leftTypesOf(leftCaptures, scope, &falsey);
if (UNEXPECTED(leftFalseyTypes.isUndef())) return zv::Val();
if (leftTruthyTypes.isNull() || leftFalseyTypes.isNull()) return zv::Val::null();
zv::Val leftTruthyScope = applyRooted(scope, leftTruthyTypes.raw(), identical);
if (UNEXPECTED(leftTruthyScope.isUndef())) return zv::Val();
zv::Val leftFalseyScope = applyRooted(scope, leftFalseyTypes.raw(), identical);
if (UNEXPECTED(leftFalseyScope.isUndef())) return zv::Val();
zv::Val rightTruthyTypes = rightTypesOf(rightCaptures, leftFalseyScope.raw(), &truthy);
if (UNEXPECTED(rightTruthyTypes.isUndef())) return zv::Val();
if (rightTruthyTypes.isNull()) return zv::Val::null();
zv::Val leftTruthyScope = applyRooted(scope, leftTruthyTypes.raw(), identical);
if (UNEXPECTED(leftTruthyScope.isUndef())) return zv::Val();
zv::Val rightTruthyScope = applyRooted(leftFalseyScope.raw(), rightTruthyTypes.raw(), isObjectCall);
if (UNEXPECTED(rightTruthyScope.isUndef())) return zv::Val();

Expand Down
Loading