[Python-ideas] possible extension to how the new StopIteration is handled (python >=3.3)

Stephan Sahm Stephan.Sahm at gmx.de
Fri Oct 3 08:36:43 CEST 2014


Thank you both very much,

I see that this longevity problem is really crucial. A pity for me ;)
best wishes,
Stephan

On 3 October 2014 00:15, Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:

> Chris Angelico wrote:
>
>> it
>> would mean that the generator would have to retain a reference to its
>> return value, which is contrary to what most people will expect of
>> function return values. It might make for unnecessary object
>> longevity.
>>
>
> This was debated during the yield-from discussions and
> decided against. If I remember rightly, unexpected longevity
> of return values was one of the main objections.
>
> --
> Greg
>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
> Code of Conduct: http://python.org/psf/codeofconduct/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20141003/821fcccd/attachment.html>


More information about the Python-ideas mailing list