diff options
author | Georg Brandl <georg@python.org> | 2014-10-31 08:29:38 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2014-10-31 08:29:38 (GMT) |
commit | c182f888db39408790e973dad696c849fd3cada9 (patch) | |
tree | 5d028d506654c0390149f3e40ea269799a6d8925 /Doc/tutorial | |
parent | e969b1b80ecfcf3de576a46ff168ccd08767b999 (diff) | |
download | cpython-c182f888db39408790e973dad696c849fd3cada9.zip cpython-c182f888db39408790e973dad696c849fd3cada9.tar.gz cpython-c182f888db39408790e973dad696c849fd3cada9.tar.bz2 |
minor grammar fixes (from docs@python.org)
Diffstat (limited to 'Doc/tutorial')
-rw-r--r-- | Doc/tutorial/classes.rst | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Doc/tutorial/classes.rst b/Doc/tutorial/classes.rst index 8970a66..d82adf6 100644 --- a/Doc/tutorial/classes.rst +++ b/Doc/tutorial/classes.rst @@ -826,7 +826,7 @@ Generators :term:`Generator`\s are a simple and powerful tool for creating iterators. They are written like regular functions but use the :keyword:`yield` statement whenever they want to return data. Each time :func:`next` is called on it, the -generator resumes where it left-off (it remembers all the data values and which +generator resumes where it left off (it remembers all the data values and which statement was last executed). An example shows that generators can be trivially easy to create:: @@ -844,7 +844,7 @@ easy to create:: o g -Anything that can be done with generators can also be done with class based +Anything that can be done with generators can also be done with class-based iterators as described in the previous section. What makes generators so compact is that the :meth:`__iter__` and :meth:`~generator.next` methods are created automatically. |