| 
        php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits             
             [2015-08-23 17:15 UTC] cmb@php.net
 
-Status: Open
+Status: Verified
  [2015-08-23 17:15 UTC] cmb@php.net
  [2020-04-15 14:59 UTC] nikic@php.net
 
-Summary: serialization drops the iterator class.
+Summary: ArrayObject serialization drops the iterator class
  [2020-04-20 09:57 UTC] nikic@php.net
  [2020-04-20 09:57 UTC] nikic@php.net
 
-Status: Verified
+Status: Closed
  | 
    |||||||||||||||||||||||||||||||||||||
            
                 
                Copyright © 2001-2025 The PHP GroupAll rights reserved.  | 
        Last updated: Tue Nov 04 10:00:02 2025 UTC | 
Description: ------------ ArrayObject does not appear to be serializing the classname of the iterator. When an ArrayObject is deserialized the iterator is always set to the default ArrayIterator class. Test script: --------------- <?php class MyIterator extends ArrayIterator {} $a = new ArrayObject(); $a->setIteratorClass('MyIterator'); var_dump($a->getIteratorClass()); var_dump($a->serialize()); var_dump(unserialize(serialize($a))->getIteratorClass());