Skip to content

Commit b4ed730

Browse files
[3.12] gh-110527: Improve PySet_Clear docs (GH-110528) (#110928)
gh-110527: Improve `PySet_Clear` docs (GH-110528) (cherry picked from commit bfc1cd8) Co-authored-by: Nikita Sobolev <[email protected]>
1 parent 7de3c8b commit b4ed730

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Doc/c-api/set.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,4 +163,6 @@ subtypes but not for instances of :class:`frozenset` or its subtypes.
163163
164164
.. c:function:: int PySet_Clear(PyObject *set)
165165
166-
Empty an existing set of all elements.
166+
Empty an existing set of all elements. Return ``0`` on
167+
success. Return ``-1`` and raise :exc:`SystemError` if *set* is not an instance of
168+
:class:`set` or its subtype.

0 commit comments

Comments
 (0)