11 Apr
2009
11 Apr
'09
11:44 p.m.
Nick Coghlan wrote:
Since the language reference is actually silent on the topic of caching the bound method when iterating over an object,
Since it's silent about that, if you write a for-loop that relies on presence or absence of cacheing behaviour, the result is undefined. The behaviour of yield-from on the same iterator would also be undefined. It's meaningless to talk about whether one undefined construct has the same semantics as another. -- Greg