diff options
author | Georg Brandl <georg@python.org> | 2009-02-23 10:24:05 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2009-02-23 10:24:05 (GMT) |
commit | 5579ba9183c7881d38bd3e32da20ee5e35406238 (patch) | |
tree | ff9d7ca149f9dc05e7a7c39cdddf9637933009df /Doc | |
parent | 9249f8034dfc47345cdbeeca3de8bc7afa2c4027 (diff) | |
download | cpython-5579ba9183c7881d38bd3e32da20ee5e35406238.zip cpython-5579ba9183c7881d38bd3e32da20ee5e35406238.tar.gz cpython-5579ba9183c7881d38bd3e32da20ee5e35406238.tar.bz2 |
#5348: format() converts all kinds of values.
Diffstat (limited to 'Doc')
-rw-r--r-- | Doc/library/functions.rst | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/Doc/library/functions.rst b/Doc/library/functions.rst index b735c8f..e1436f8 100644 --- a/Doc/library/functions.rst +++ b/Doc/library/functions.rst @@ -415,14 +415,15 @@ are always available. They are listed here in alphabetical order. pair: str; format single: __format__ - Convert a string or a number to a "formatted" representation, as controlled - by *format_spec*. The interpretation of *format_spec* will depend on the - type of the *value* argument, however there is a standard formatting syntax - that is used by most built-in types: :ref:`formatspec`. + Convert a *value* to a "formatted" representation, as controlled by + *format_spec*. The interpretation of *format_spec* will depend on the type + of the *value* argument, however there is a standard formatting syntax that + is used by most built-in types: :ref:`formatspec`. .. note:: - ``format(value, format_spec)`` merely calls ``value.__format__(format_spec)``. + ``format(value, format_spec)`` merely calls + ``value.__format__(format_spec)``. .. function:: frozenset([iterable]) |