Kaydet (Commit) 763b50f9 authored tarafından Fredrik Lundh's avatar Fredrik Lundh

docstring tweaks: count counts non-overlapping substrings, not

total number of occurences
üst b9759731
......@@ -2159,9 +2159,9 @@ string_capitalize(PyStringObject *self)
PyDoc_STRVAR(count__doc__,
"S.count(sub[, start[, end]]) -> int\n\
\n\
Return the number of occurrences of substring sub in string\n\
S[start:end]. Optional arguments start and end are\n\
interpreted as in slice notation.");
Return the number of non-overlapping occurrences of substring sub in\n\
string S[start:end]. Optional arguments start and end are interpreted\n\
as in slice notation.");
static PyObject *
string_count(PyStringObject *self, PyObject *args)
......
......@@ -5078,8 +5078,8 @@ onError:
PyDoc_STRVAR(count__doc__,
"S.count(sub[, start[, end]]) -> int\n\
\n\
Return the number of occurrences of substring sub in Unicode string\n\
S[start:end]. Optional arguments start and end are\n\
Return the number of non-overlapping occurrences of substring sub in\n\
Unicode string S[start:end]. Optional arguments start and end are\n\
interpreted as in slice notation.");
static PyObject *
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment