OLD | NEW |
1 | 1 |
2 /* Generator object interface */ | 2 /* Generator object interface */ |
3 | 3 |
4 #ifndef Py_GENOBJECT_H | 4 #ifndef Py_GENOBJECT_H |
5 #define Py_GENOBJECT_H | 5 #define Py_GENOBJECT_H |
6 #ifdef __cplusplus | 6 #ifdef __cplusplus |
7 extern "C" { | 7 extern "C" { |
8 #endif | 8 #endif |
9 | 9 |
10 struct _frame; /* Avoid including frameobject.h */ | 10 struct _frame; /* Avoid including frameobject.h */ |
(...skipping 15 matching lines...) Expand all Loading... |
26 PyObject *gi_weakreflist; | 26 PyObject *gi_weakreflist; |
27 } PyGenObject; | 27 } PyGenObject; |
28 | 28 |
29 PyAPI_DATA(PyTypeObject) PyGen_Type; | 29 PyAPI_DATA(PyTypeObject) PyGen_Type; |
30 | 30 |
31 #define PyGen_Check(op) PyObject_TypeCheck(op, &PyGen_Type) | 31 #define PyGen_Check(op) PyObject_TypeCheck(op, &PyGen_Type) |
32 #define PyGen_CheckExact(op) (Py_TYPE(op) == &PyGen_Type) | 32 #define PyGen_CheckExact(op) (Py_TYPE(op) == &PyGen_Type) |
33 | 33 |
34 PyAPI_FUNC(PyObject *) PyGen_New(struct _frame *); | 34 PyAPI_FUNC(PyObject *) PyGen_New(struct _frame *); |
35 PyAPI_FUNC(int) PyGen_NeedsFinalizing(PyGenObject *); | 35 PyAPI_FUNC(int) PyGen_NeedsFinalizing(PyGenObject *); |
| 36 PyAPI_FUNC(int) PyGen_FetchStopIterationValue(PyObject **); |
36 | 37 |
37 #ifdef __cplusplus | 38 #ifdef __cplusplus |
38 } | 39 } |
39 #endif | 40 #endif |
40 #endif /* !Py_GENOBJECT_H */ | 41 #endif /* !Py_GENOBJECT_H */ |
OLD | NEW |