summaryrefslogtreecommitdiffstats
path: root/Doc/c-api
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2021-09-07 11:43:33 (GMT)
committerGitHub <noreply@github.com>2021-09-07 11:43:33 (GMT)
commit53257cf19fc06fff446815b3278d4b80ec3e7ba3 (patch)
treed8277cc47a08212a2fa891552e7657d26a7bc79a /Doc/c-api
parentfc840736e54da0557616882012f362b809490165 (diff)
downloadcpython-53257cf19fc06fff446815b3278d4b80ec3e7ba3.zip
cpython-53257cf19fc06fff446815b3278d4b80ec3e7ba3.tar.gz
cpython-53257cf19fc06fff446815b3278d4b80ec3e7ba3.tar.bz2
bpo-45123: PyAiter_Check and PyObject_GetAiter fix & rename. (GH-28194) (GH-28199)
Fix PyAiter_Check to only check for the `__anext__` presense (not for `__aiter__`). Rename `PyAiter_Check()` to `PyAIter_Check()`, `PyObject_GetAiter()` -> `PyObject_GetAIter()`.
Diffstat (limited to 'Doc/c-api')
-rw-r--r--Doc/c-api/iter.rst2
-rw-r--r--Doc/c-api/object.rst2
2 files changed, 2 insertions, 2 deletions
diff --git a/Doc/c-api/iter.rst b/Doc/c-api/iter.rst
index 63290e0..f7106f4 100644
--- a/Doc/c-api/iter.rst
+++ b/Doc/c-api/iter.rst
@@ -12,7 +12,7 @@ There are two functions specifically for working with iterators.
Return non-zero if the object *o* supports the iterator protocol, and ``0``
otherwise. This function always succeeds.
-.. c:function:: int PyAiter_Check(PyObject *o)
+.. c:function:: int PyAIter_Check(PyObject *o)
Returns non-zero if the object 'obj' provides :class:`AsyncIterator`
protocols, and ``0`` otherwise. This function always succeeds.
diff --git a/Doc/c-api/object.rst b/Doc/c-api/object.rst
index 70cff69..17e3707 100644
--- a/Doc/c-api/object.rst
+++ b/Doc/c-api/object.rst
@@ -358,7 +358,7 @@ Object Protocol
iterated.
-.. c:function:: PyObject* PyObject_GetAiter(PyObject *o)
+.. c:function:: PyObject* PyObject_GetAIter(PyObject *o)
This is the equivalent to the Python expression ``aiter(o)``. Takes an
:class:`AsyncIterable` object and returns an :class:`AsyncIterator` for it.