If your iterator is designed to return a list each iteration and an empty list is valid then you will prematurely terminate.Uhm, the whole idea with the above is that if you want "a list" from the iterator the iterator returns an array reference, just as you do if you want to return two or more "lists" from a subroutine or have several "lists" in a list or array.
In reply to Re^3: How To: Make An Iterator
by Anonymous Monk
in thread How To: Make An Iterator
by Limbic~Region
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |