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
<?phpclass C {
publicint$intProp;
}
$c = newC();
$a = newArrayObject($c);
$a['intProp'] = [];
var_export($c);
// Alternate snippet that would be an Uncaught TypeError: Cannot assign array to property C::$intProp of type int// unset($c->intProp);// $c->intProp = [];
Resulted in this output:
\C::__set_state(array(
'intProp' =>
array (
),
))
But I expected this output instead:
Uncaught TypeError: Cannot assign array to property C::$intProp of type int