[Python-checkins] r85609 - python/branches/py3k/Doc/library/stdtypes.rst

georg.brandl python-checkins at python.org
Sun Oct 17 11:19:05 CEST 2010


Author: georg.brandl
Date: Sun Oct 17 11:19:03 2010
New Revision: 85609

Log:
#8556: use less confusing mapping key in example.

Modified:
   python/branches/py3k/Doc/library/stdtypes.rst

Modified: python/branches/py3k/Doc/library/stdtypes.rst
==============================================================================
--- python/branches/py3k/Doc/library/stdtypes.rst	(original)
+++ python/branches/py3k/Doc/library/stdtypes.rst	Sun Oct 17 11:19:03 2010
@@ -1414,9 +1414,8 @@
 dictionary inserted immediately after the ``'%'`` character. The mapping key
 selects the value to be formatted from the mapping.  For example:
 
-
-   >>> print('%(language)s has %(#)03d quote types.' % \
-   ...       {'language': "Python", "#": 2})
+   >>> print('%(language)s has %(number)03d quote types.' %
+   ...       {'language': "Python", "number": 2})
    Python has 002 quote types.
 
 In this case no ``*`` specifiers may occur in a format (since they require a


More information about the Python-checkins mailing list