Merged revisions 74404 via svnmerge from

svn+ssh://pythondev@svn.python.org/python/trunk

........
  r74404 | georg.brandl | 2009-08-13 14:05:52 +0200 (Do, 13 Aug 2009) | 1 line

  Use locale.format_string() for more than one specifier.
........
This commit is contained in:
Georg Brandl 2009-08-13 12:06:43 +00:00
parent 3517e378d8
commit 4a52a4c3bb
1 changed files with 2 additions and 2 deletions

View File

@ -61,8 +61,8 @@ formatting numbers with group separators::
>>> x = 1234567.8
>>> locale.format("%d", x, grouping=True)
'1,234,567'
>>> locale.format("%s%.*f", (conv['currency_symbol'],
... conv['frac_digits'], x), grouping=True)
>>> locale.format_string("%s%.*f", (conv['currency_symbol'],
... conv['frac_digits'], x), grouping=True)
'$1,234,567.80'