--TEST-- SPL: Iterator: Overloaded object and destruction --FILE-- foo(); } } $obj = new TestIteratorIterator(new Test); $obj->foo(); unset($obj); ?> ===DONE=== --EXPECT-- Test::foo() TestIteratorIterator::__destruct() Test::foo() ===DONE===