File tree Expand file tree Collapse file tree 3 files changed +7
-0
lines changed Expand file tree Collapse file tree 3 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -50,6 +50,8 @@ something like this::
50
50
51
51
The enum value used to represent different results of :c:func: `PyIter_Send `.
52
52
53
+ .. versionadded :: 3.10
54
+
53
55
54
56
.. c :function :: PySendResult PyIter_Send (PyObject *iter, PyObject *arg, PyObject **presult)
55
57
@@ -58,3 +60,5 @@ something like this::
58
60
- ``PYGEN_RETURN `` if iterator returns. Return value is returned via *presult *.
59
61
- ``PYGEN_NEXT `` if iterator yields. Yielded value is returned via *presult *.
60
62
- ``PYGEN_ERROR `` if iterator has raised and exception. *presult * is set to ``NULL ``.
63
+
64
+ .. versionadded :: 3.10
Original file line number Diff line number Diff line change @@ -338,6 +338,7 @@ PyAPI_FUNC(int) PyIter_Check(PyObject *);
338
338
NULL with an exception means an error occurred. */
339
339
PyAPI_FUNC (PyObject * ) PyIter_Next (PyObject * );
340
340
341
+ #if !defined(Py_LIMITED_API ) || Py_LIMITED_API + 0 >= 0x030A0000
341
342
typedef enum {
342
343
PYGEN_RETURN = 0 ,
343
344
PYGEN_ERROR = -1 ,
@@ -353,6 +354,7 @@ typedef enum {
353
354
- PYGEN_NEXT (1) if generator has yielded.
354
355
'result' parameter is filled with yielded value. */
355
356
PyAPI_FUNC (PySendResult ) PyIter_Send (PyObject * , PyObject * , PyObject * * );
357
+ #endif
356
358
357
359
358
360
/* === Number Protocol ================================================== */
Original file line number Diff line number Diff line change @@ -287,6 +287,7 @@ EXPORT_FUNC(PyInterpreterState_GetID)
287
287
EXPORT_FUNC (PyInterpreterState_New )
288
288
EXPORT_FUNC (PyIter_Check )
289
289
EXPORT_FUNC (PyIter_Next )
290
+ EXPORT_FUNC (PyIter_Send )
290
291
EXPORT_FUNC (PyList_Append )
291
292
EXPORT_FUNC (PyList_AsTuple )
292
293
EXPORT_FUNC (PyList_GetItem )
You can’t perform that action at this time.
0 commit comments