bpo-42528: Improve the docs of most Py*_Check{,Exact} API calls (GH-23602)

I think that none of these API calls can fail, but only few of them are
documented as such. Add the sentence "This function always succeeds" (which is
the same already used e.g. by PyNumber_Check) to all of them.
This commit is contained in:
Antonio Cuni 2021-01-06 12:38:26 +01:00 committed by GitHub
parent 1a9f51ed12
commit 315fc52db1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
26 changed files with 74 additions and 52 deletions

View file

@ -91,13 +91,13 @@ access internal read-only data of Unicode objects:
.. c:function:: int PyUnicode_Check(PyObject *o)
Return true if the object *o* is a Unicode object or an instance of a Unicode
subtype.
subtype. This function always succeeds.
.. c:function:: int PyUnicode_CheckExact(PyObject *o)
Return true if the object *o* is a Unicode object, but not an instance of a
subtype.
subtype. This function always succeeds.
.. c:function:: int PyUnicode_READY(PyObject *o)