You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
A property read through an erased receiver, narrowed by instanceof, is dereferenced as a raw pointer while still a tagged cell (SIGSEGV). #459
A property read through an erased receiver, narrowed by instanceof, is dereferenced as a raw pointer while still a tagged cell (SIGSEGV).
Repro
<?phpclass Node {}
class IntConst extends Node { publicfunction__construct(publicint$value) {} }
class Arm { publicfunction__construct(public ?Node$value) {} }
class Other { publicstring$value = 'x'; }
functionf(array$arms): void
{
$seen = [];
foreach ($armsas$arm) {
if ($arm->valueinstanceof IntConst && !isset($seen[$arm->value->value])) {
$seen[$arm->value->value] = true;
echo$arm->value->value, "\n";
}
}
}
f([newArm(newIntConst(7)), newArm(null), newArm(newIntConst(9)), newOther()]);
Expected (php)
7
9
Actual (manticore dc3883d9, Darwin arm64)
[exit code 139 — SIGSEGV]
Tracking
Known-bug repro: tests/aot/repro/crash/narrowed_erased_prop_read.php — bash tests/aot/xfail.sh -k narrowed_erased_prop_read reports XFAIL while this is open and XPASS once it is fixed; then move the repro into tests/aot/cases/ and close this issue.
Activity