26 Mar
2009
26 Mar
'09
2:24 a.m.
Jacob Holm wrote:
But if you throw another exception and it is converted to a StopIteration by the subiterator, this should definitely stop the subiterator and get a return value.
Not if it simply raises a StopIteration from the throw call. It would have to mark itself as completed, return normally from the throw and then raise StopIteration on the next call to next() or send(). -- Greg