diff options
author | Yury Selivanov <yury@magic.io> | 2018-01-23 00:11:18 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-23 00:11:18 (GMT) |
commit | f23746a934177c48eff754411aba54c31d6be2f0 (patch) | |
tree | 4b32964b53fa87701f71c71937792f2489b7bbb4 /Python/pylifecycle.c | |
parent | 9089a265918754d95e105a7c4c409ac9352c87bb (diff) | |
download | cpython-f23746a934177c48eff754411aba54c31d6be2f0.zip cpython-f23746a934177c48eff754411aba54c31d6be2f0.tar.gz cpython-f23746a934177c48eff754411aba54c31d6be2f0.tar.bz2 |
bpo-32436: Implement PEP 567 (#5027)
Diffstat (limited to 'Python/pylifecycle.c')
-rw-r--r-- | Python/pylifecycle.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c index 2f61db0..d46784a 100644 --- a/Python/pylifecycle.c +++ b/Python/pylifecycle.c @@ -4,6 +4,8 @@ #include "Python-ast.h" #undef Yield /* undefine macro conflicting with winbase.h */ +#include "internal/context.h" +#include "internal/hamt.h" #include "internal/pystate.h" #include "grammar.h" #include "node.h" @@ -758,6 +760,9 @@ _Py_InitializeCore(const _PyCoreConfig *core_config) return _Py_INIT_ERR("can't initialize warnings"); } + if (!_PyContext_Init()) + return _Py_INIT_ERR("can't init context"); + /* This call sets up builtin and frozen import support */ if (!interp->core_config._disable_importlib) { err = initimport(interp, sysmod); @@ -1176,6 +1181,7 @@ Py_FinalizeEx(void) _Py_HashRandomization_Fini(); _PyArg_Fini(); PyAsyncGen_Fini(); + _PyContext_Fini(); /* Cleanup Unicode implementation */ _PyUnicode_Fini(); |