summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorNikita Sobolev <mail@sobolevn.me>2023-10-16 13:05:09 (GMT)
committerGitHub <noreply@github.com>2023-10-16 13:05:09 (GMT)
commitbfc1cd8145db00df23fbbd2ed95324bb96c0b25b (patch)
tree743b34554790bec34aa38b17c601294d6323596e /Doc
parentc2192a2bee17e2ce80c5af34410ccd0c8b6e08aa (diff)
downloadcpython-bfc1cd8145db00df23fbbd2ed95324bb96c0b25b.zip
cpython-bfc1cd8145db00df23fbbd2ed95324bb96c0b25b.tar.gz
cpython-bfc1cd8145db00df23fbbd2ed95324bb96c0b25b.tar.bz2
gh-110527: Improve `PySet_Clear` docs (#110528)
Diffstat (limited to 'Doc')
-rw-r--r--Doc/c-api/set.rst4
1 files changed, 3 insertions, 1 deletions
diff --git a/Doc/c-api/set.rst b/Doc/c-api/set.rst
index 1e8a095..09c0fb6 100644
--- a/Doc/c-api/set.rst
+++ b/Doc/c-api/set.rst
@@ -163,4 +163,6 @@ subtypes but not for instances of :class:`frozenset` or its subtypes.
.. c:function:: int PySet_Clear(PyObject *set)
- Empty an existing set of all elements.
+ Empty an existing set of all elements. Return ``0`` on
+ success. Return ``-1`` and raise :exc:`SystemError` if *set* is not an instance of
+ :class:`set` or its subtype.