From: Andrew Svetlov Date: Fri, 28 Sep 2012 13:31:06 +0000 (+0300) Subject: Update documentation for string.replace. Thanks to docs@ X-Git-Tag: v2.7.4rc1~531 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9ac20231e02512bd42d3dfc7e0d13dde28a4a96b;p=thirdparty%2FPython%2Fcpython.git Update documentation for string.replace. Thanks to docs@ --- diff --git a/Doc/library/string.rst b/Doc/library/string.rst index ef1a0c265bcd..a7336c477c02 100644 --- a/Doc/library/string.rst +++ b/Doc/library/string.rst @@ -1029,9 +1029,9 @@ not be removed until Python 3. The functions defined in this module are: reached. Strings starting with a sign are handled correctly. -.. function:: replace(str, old, new[, maxreplace]) +.. function:: replace(s, old, new[, maxreplace]) - Return a copy of string *str* with all occurrences of substring *old* replaced + Return a copy of string *s* with all occurrences of substring *old* replaced by *new*. If the optional argument *maxreplace* is given, the first *maxreplace* occurrences are replaced.