diff options
Diffstat (limited to 'Python/errors.c')
-rw-r--r-- | Python/errors.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Python/errors.c b/Python/errors.c index 6c5fe41142..211881ca5e 100644 --- a/Python/errors.c +++ b/Python/errors.c @@ -1241,6 +1241,17 @@ _PyErr_InitTypes(PyInterpreterState *interp) } +void +_PyErr_FiniTypes(PyInterpreterState *interp) +{ + if (!_Py_IsMainInterpreter(interp)) { + return; + } + + _PyStructSequence_FiniType(&UnraisableHookArgsType); +} + + static PyObject * make_unraisable_hook_args(PyThreadState *tstate, PyObject *exc_type, PyObject *exc_value, PyObject *exc_tb, |