diff options
author | Victor Stinner <vstinner@python.org> | 2019-11-20 11:25:50 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-20 11:25:50 (GMT) |
commit | 7247407c35330f3f6292f1d40606b7ba6afd5700 (patch) | |
tree | fa9307b2cdbf41bf30c90daf12c76dd439949cfd /Python/pystate.c | |
parent | 488d02a24142948bfb1fafd19fa48e61fcbbabc5 (diff) | |
download | cpython-7247407c35330f3f6292f1d40606b7ba6afd5700.zip cpython-7247407c35330f3f6292f1d40606b7ba6afd5700.tar.gz cpython-7247407c35330f3f6292f1d40606b7ba6afd5700.tar.bz2 |
bpo-36854: Move _PyRuntimeState.gc to PyInterpreterState (GH-17287)
* Rename _PyGC_InitializeRuntime() to _PyGC_InitState()
* finalize_interp_clear() now also calls _PyGC_Fini() in
subinterpreters (clear the GC state).
Diffstat (limited to 'Python/pystate.c')
-rw-r--r-- | Python/pystate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/pystate.c b/Python/pystate.c index 93f0ce7..2fc563b 100644 --- a/Python/pystate.c +++ b/Python/pystate.c @@ -58,7 +58,6 @@ _PyRuntimeState_Init_impl(_PyRuntimeState *runtime) runtime->open_code_userdata = open_code_userdata; runtime->audit_hook_head = audit_hook_head; - _PyGC_InitializeRuntime(&runtime->gc); _PyEval_Initialize(&runtime->ceval); PyPreConfig_InitPythonConfig(&runtime->preconfig); @@ -208,6 +207,7 @@ PyInterpreterState_New(void) _PyRuntimeState *runtime = &_PyRuntime; interp->runtime = runtime; + _PyGC_InitState(&interp->gc); PyConfig_InitPythonConfig(&interp->config); interp->eval_frame = _PyEval_EvalFrameDefault; |