On 01/30/2017 03:03 AM, Profile Anaysis wrote:
> I need to yield from a complex recursive function too allow visualizing
> what it is doing.
>
> e.g., if it is a tree searching algorithm, I'd like to yield for each
> node so that the current state can be shown visually.

I used tree iteration as a Generator example here:

  http://ddili.org/ders/d.en/fibers.html

It's in the code where the function 'byNode' appears. (The example builds on an earlier tree iteration code in the same chapter.)

Ali

Reply via email to