From a6066ce6b1115b8a8bff3d30848bad0be0863f08 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Thu, 9 Oct 2014 11:14:04 +0200 Subject: [PATCH] Closes #22580: Fix documentation of PyUnicode_Tailmatch() The result type is Py_ssize_t (and not int). --- Doc/c-api/unicode.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/c-api/unicode.rst b/Doc/c-api/unicode.rst index 4ef437c6ce..8932915da9 100644 --- a/Doc/c-api/unicode.rst +++ b/Doc/c-api/unicode.rst @@ -1035,7 +1035,7 @@ They all return *NULL* or ``-1`` if an exception occurs. Unicode string. -.. c:function:: int PyUnicode_Tailmatch(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end, int direction) +.. c:function:: Py_ssize_t PyUnicode_Tailmatch(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end, int direction) Return 1 if *substr* matches ``str[start:end]`` at the given tail end (*direction* == -1 means to do a prefix match, *direction* == 1 a suffix match), -- 2.50.1