changeset: 96207:c8a3e49f35e7 user: Yury Selivanov date: Fri May 22 11:30:45 2015 -0400 files: Doc/whatsnew/3.5.rst description: docs: Mention PEP 479 in whatsnew. Issue 22906. diff -r 2771a0ac806b -r c8a3e49f35e7 Doc/whatsnew/3.5.rst --- a/Doc/whatsnew/3.5.rst Fri May 22 11:16:47 2015 -0400 +++ b/Doc/whatsnew/3.5.rst Fri May 22 11:30:45 2015 -0400 @@ -209,6 +209,27 @@ :pep:`475` -- Retry system calls failing with EINTR +PEP 479: Change StopIteration handling inside generators +-------------------------------------------------------- + +:pep:`479` changes the behavior of generators: when a :exc:`StopIteration` +exception is raised inside a generator, it is replaced with a +:exc:`RuntimeError`. To enable the feature a ``__future__`` import should +be used:: + + from __future__ import generator_stop + +Without a ``__future__`` import, a :exc:`PendingDeprecationWarning` will be +raised. + +PEP written by Chris Angelico and Guido van Rossum. Implemented by +Chris Angelico, Yury Selivanov and Nick Coghlan. + +.. seealso:: + + :pep:`479` -- Change StopIteration handling inside generators + + PEP 486: Make the Python Launcher aware of virtual environments ---------------------------------------------------------------