summaryrefslogtreecommitdiffstats
path: root/Doc/c-api/long.rst
diff options
context:
space:
mode:
authorAntonio Cuni <anto.cuni@gmail.com>2021-01-06 11:38:26 (GMT)
committerGitHub <noreply@github.com>2021-01-06 11:38:26 (GMT)
commit315fc52db17b19fe30aa9193f26adf69e18d8844 (patch)
tree90a8795e94974c667c306f8e508c4df674bfc7b8 /Doc/c-api/long.rst
parent1a9f51ed12feb4d95ad6d0faf610a030c05b9f5e (diff)
downloadcpython-315fc52db17b19fe30aa9193f26adf69e18d8844.zip
cpython-315fc52db17b19fe30aa9193f26adf69e18d8844.tar.gz
cpython-315fc52db17b19fe30aa9193f26adf69e18d8844.tar.bz2
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.
Diffstat (limited to 'Doc/c-api/long.rst')
-rw-r--r--Doc/c-api/long.rst4
1 files changed, 2 insertions, 2 deletions
diff --git a/Doc/c-api/long.rst b/Doc/c-api/long.rst
index 4d859fb..4201490 100644
--- a/Doc/c-api/long.rst
+++ b/Doc/c-api/long.rst
@@ -27,13 +27,13 @@ distinguished from a number. Use :c:func:`PyErr_Occurred` to disambiguate.
.. c:function:: int PyLong_Check(PyObject *p)
Return true if its argument is a :c:type:`PyLongObject` or a subtype of
- :c:type:`PyLongObject`.
+ :c:type:`PyLongObject`. This function always succeeds.
.. c:function:: int PyLong_CheckExact(PyObject *p)
Return true if its argument is a :c:type:`PyLongObject`, but not a subtype of
- :c:type:`PyLongObject`.
+ :c:type:`PyLongObject`. This function always succeeds.
.. c:function:: PyObject* PyLong_FromLong(long v)