Small grammatical fixes courtesy of francismb@email.de

This commit is contained in:
Chris Angelico 2014-12-07 01:30:37 +11:00
parent 6037436ec8
commit d6edada20d
1 changed files with 2 additions and 2 deletions

View File

@ -160,11 +160,11 @@ generator terminated "normally", i.e. it did not raise an exception).
A subtle issue is what will happen if the caller, having caught the
``RuntimeError``, calls the generator object's ``__next__()`` method
again. The answer is that it from this point on it will raise
again. The answer is that from this point on it will raise
``StopIteration`` -- the behavior is the same as when any other
exception was raised by the generator.
Another logical consequence of the proposal: if somone uses
Another logical consequence of the proposal: if someone uses
``g.throw(StopIteration)`` to throw a ``StopIteration`` exception into
a generator, if the generator doesn't catch it (which it could do
using a ``try/except`` around the ``yield``), it will be transformed