Fix for bug #321 with deep nesting loops (http://alexeyrybak.com/blitz/bt/view.php?id=321)

Quoting http://flylib.com/books/en/2.565.1.50/1/:

Preserving the Internal Pointer
When iterating through a HashTable, particularly one containing userspace variables, it's not uncommon to encounter circular references, or at least self-overlapping loops. If one iteration context starts looping through a HashTable and the internal pointer reachesfor examplethe halfway mark, a subordinate iterator starts looping through the same HashTable and would obliterate the current internal pointer position, leaving the HashTable at the end when it arrived back at the first loop.
The way this is resolvedboth within the zend_hash_apply implementation and within custom move forward usesis to supply an external pointer in the form of a HashPosition variable.