|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-09-03 10:42 UTC] derick@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 21:00:02 2025 UTC |
Description: ------------ Using array access on $this in ArrayObject::offsetSet() causes a segmentation fault. (Calling parent::offsetSet() instead, works fine) Reproduce code: --------------- class AOTest extends ArrayObject { public function offsetSet($index, $newval) { $this[$index] = (int)$newval; } } $a = new AOTest(); $a['test'] = "10 doves"; var_dump((array)$a); Expected result: ---------------- array(1) { ["test"]=> int(10) } Actual result: -------------- Segmentation fault