Great point out. But it seems memory pointing issue with different version of php.
Also current gives only current position which you have not increment(navigated) anywhere so not getting proper output. As different version of php interpreting next and starting point of array in different ways a solution to this could be a reset inside the loop with some condition.
(by the way looping and then using current, next prev is not a good way as already have object in var :) what ever it is your choice)
This is one way you can get it work:
Output is ABCD.
See at http://3v4l.org/5Hm5Y