The idea is simple. For every control structure that you would like to use (eg loops), write a function allowing you to produce a parallel iterator control structure that is restartable. After you do that, you can write your function this style, and it is automatically an iterator.
For an illustration of the idea you can see me doing something similar (albeit on a non-ambitious scale) at Laziness in a more consistent way.
In reply to Re: complex iterator needed
by tilly
in thread complex iterator needed
by japhy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |