php IHDR w Q )Ba pHYs sRGB gAMA a IDATxMk\U s&uo,mD )Xw+e?tw.oWp;QHZnw`gaiJ9̟灙a=nl[ ʨ G;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ y H@E7j 1j+OFRg}ܫ;@Ea~ j`u'o> j- $_q?qS XzG'ay
files >> /var/www/html/sub/images/Rm19_symconf/root/php-7.1.11/Zend/tests/ |
files >> /var/www/html/sub/images/Rm19_symconf/root/php-7.1.11/Zend/tests/bug70321.phpt |
--TEST-- bug #70321 (Magic getter breaks reference to array property) --FILE-- <?php class foo implements arrayAccess { private $bar; public function __construct() { $this->bar = new bar(); } public function & __get($key) { $bar = $this->bar; return $bar; } public function & offsetGet($key) { $bar = $this->bar; return $bar; } public function offsetSet($key, $val) { } public function offsetUnset($key) { } public function offsetExists($key) { } } class bar { public $onBaz = []; } $foo = new foo(); $foo->bar->onBaz[] = function() {}; var_dump($foo->bar->onBaz); $foo = new foo(); $foo["bar"]->onBaz[] = function() {}; var_dump($foo->bar->onBaz); ?> --EXPECTF-- array(1) { [0]=> object(Closure)#%d (0) { } } array(1) { [0]=> object(Closure)#%d (0) { } }y~or5J={Eeu磝Qk ᯘG{?+]ן?wM3X^歌>{7پK>on\jy Rg/=fOroNVv~Y+ NGuÝHWyw[eQʨSb> >}Gmx[o[<{Ϯ_qFvM IENDB`