Commit 2c1d1d63 authored by R David Murray's avatar R David Murray

#15355: Mention already-executing Exception in generator docs.

Patch by Chris Jerdonek.
parent 433ef3b5
......@@ -354,8 +354,15 @@ called, allowing any pending :keyword:`finally` clauses to execute.
.. index:: object: generator
The following generator's methods can be used to control the execution of a
generator function:
Generator-iterator methods
^^^^^^^^^^^^^^^^^^^^^^^^^^
This subsection describes the methods of a generator iterator. They can
be used to control the execution of a generator function.
Note that calling any of the generator methods below when the generator
is already executing raises a :exc:`ValueError` exception.
.. index:: exception: StopIteration
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment