summaryrefslogtreecommitdiffstats
path: root/Python/pystate.c
diff options
context:
space:
mode:
authorYury Selivanov <yury@magic.io>2016-09-09 05:01:51 (GMT)
committerYury Selivanov <yury@magic.io>2016-09-09 05:01:51 (GMT)
commiteb6364557f9bc4e6be29bb8a8f43308a0e080aba (patch)
tree05b7aed24dce255be67e7a60c021c319d13f43c9 /Python/pystate.c
parentb96ef55d493aded2dea18b0208070bdfab4ceb73 (diff)
downloadcpython-eb6364557f9bc4e6be29bb8a8f43308a0e080aba.zip
cpython-eb6364557f9bc4e6be29bb8a8f43308a0e080aba.tar.gz
cpython-eb6364557f9bc4e6be29bb8a8f43308a0e080aba.tar.bz2
Issue #28003: Implement PEP 525 -- Asynchronous Generators.
Diffstat (limited to 'Python/pystate.c')
-rw-r--r--Python/pystate.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/Python/pystate.c b/Python/pystate.c
index 959354d..a0a8c97 100644
--- a/Python/pystate.c
+++ b/Python/pystate.c
@@ -229,6 +229,9 @@ new_threadstate(PyInterpreterState *interp, int init)
tstate->in_coroutine_wrapper = 0;
tstate->co_extra_user_count = 0;
+ tstate->async_gen_firstiter = NULL;
+ tstate->async_gen_finalizer = NULL;
+
if (init)
_PyThreadState_Init(tstate);
@@ -408,6 +411,8 @@ PyThreadState_Clear(PyThreadState *tstate)
Py_CLEAR(tstate->c_traceobj);
Py_CLEAR(tstate->coroutine_wrapper);
+ Py_CLEAR(tstate->async_gen_firstiter);
+ Py_CLEAR(tstate->async_gen_finalizer);
}