26 Mar
2009
26 Mar
'09
8:36 a.m.
Nick Coghlan wrote:
I'm not so sure about that - we don't do it for normal iteration, so why would we do it for the new expression?
Because of the inlining principle. If you inline a subgenerator, the result is just a single generator, and closing it finalizes the whole thing.
Since the main advantage that the new expression has over simple iteration is delegating send() and throw() correctly, and I'm suggesting that shared iterators and those two methods don't mix, perhaps this whole issue can be set aside?
Sounds good to me. -- Greg