Lines Matching refs:finalizer
1186 PyObject *finalizer = NULL; in sys_set_asyncgen_hooks() local
1190 &firstiter, &finalizer)) { in sys_set_asyncgen_hooks()
1194 if (finalizer && finalizer != Py_None) { in sys_set_asyncgen_hooks()
1195 if (!PyCallable_Check(finalizer)) { in sys_set_asyncgen_hooks()
1198 Py_TYPE(finalizer)->tp_name); in sys_set_asyncgen_hooks()
1201 _PyEval_SetAsyncGenFinalizer(finalizer); in sys_set_asyncgen_hooks()
1203 else if (finalizer == Py_None) { in sys_set_asyncgen_hooks()
1243 PyObject *finalizer = _PyEval_GetAsyncGenFinalizer(); in sys_get_asyncgen_hooks_impl() local
1254 if (finalizer == NULL) { in sys_get_asyncgen_hooks_impl()
1255 finalizer = Py_None; in sys_get_asyncgen_hooks_impl()
1261 Py_INCREF(finalizer); in sys_get_asyncgen_hooks_impl()
1262 PyStructSequence_SET_ITEM(res, 1, finalizer); in sys_get_asyncgen_hooks_impl()