mirror of
https://github.com/python/cpython.git
synced 2025-08-22 17:55:18 +00:00
Document PyObject_SelfIter (#127861)
This commit is contained in:
parent
ba2d2fda93
commit
58942a07df
2 changed files with 9 additions and 0 deletions
|
@ -509,6 +509,12 @@ Object Protocol
|
||||||
iterated.
|
iterated.
|
||||||
|
|
||||||
|
|
||||||
|
.. c:function:: PyObject* PyObject_SelfIter(PyObject *obj)
|
||||||
|
|
||||||
|
This is equivalent to the Python ``__iter__(self): return self`` method.
|
||||||
|
It is intended for :term:`iterator` types, to be used in the :c:member:`PyTypeObject.tp_iter` slot.
|
||||||
|
|
||||||
|
|
||||||
.. 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
|
This is the equivalent to the Python expression ``aiter(o)``. Takes an
|
||||||
|
|
|
@ -1849,6 +1849,9 @@ PyObject_RichCompareBool:PyObject*:o1:0:
|
||||||
PyObject_RichCompareBool:PyObject*:o2:0:
|
PyObject_RichCompareBool:PyObject*:o2:0:
|
||||||
PyObject_RichCompareBool:int:opid::
|
PyObject_RichCompareBool:int:opid::
|
||||||
|
|
||||||
|
PyObject_SelfIter:PyObject*::+1:
|
||||||
|
PyObject_SelfIter:PyObject*:obj:0:
|
||||||
|
|
||||||
PyObject_SetAttr:int:::
|
PyObject_SetAttr:int:::
|
||||||
PyObject_SetAttr:PyObject*:o:0:
|
PyObject_SetAttr:PyObject*:o:0:
|
||||||
PyObject_SetAttr:PyObject*:attr_name:0:
|
PyObject_SetAttr:PyObject*:attr_name:0:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue