Improved docstrings for str and unicode methods format and __format__.

This commit is contained in:
Eric Smith 2010-11-06 19:43:44 +00:00
parent 2f0a040dfe
commit 6c84085cfb
2 changed files with 6 additions and 4 deletions

View file

@ -3582,7 +3582,8 @@ string_getnewargs(PyStringObject *v)
PyDoc_STRVAR(format__doc__,
"S.format(*args, **kwargs) -> string\n\
\n\
");
Return a formatted version of S, using substitutions from args and kwargs.\n\
The substitutions are identified by braces ('{' and '}').");
static PyObject *
string__format__(PyObject* self, PyObject* args)
@ -3616,7 +3617,7 @@ done:
PyDoc_STRVAR(p_format__doc__,
"S.__format__(format_spec) -> string\n\
\n\
");
Return a formatted version of S as described by format_spec.");
static PyMethodDef