Repository navigation
Conversation
|
We should be using some try_assign stuff anyway, otherwise this is still broken: <?php
class C {
public function __destruct() {
var_dump($GLOBALS['b']);
$GLOBALS['b'] = 43;
}
}
class D {
public static C $x;
}
D::$x = new C;
$b =& D::$x;
$array = ['b' => 42];
extract($array, EXTR_REFS);
var_dump($b);
var_dump(D::$x); // 42! type system broke :(EDIT: NVM as pointed out on Slack (sorry!) |
|
Ugh, I hate references. Relevant, maybe in 10 years we can get rid of them. 🥲 |
|
As mentioned privately, the example is actually correct. The first two prints come from the I will change this to use |
|
Turns out we can't use |
Fixes GH-18209