diff options
Diffstat (limited to 'Python/ceval.c')
-rw-r--r-- | Python/ceval.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index 149b88e..56cd9ad 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -1974,11 +1974,8 @@ _PyEvalFramePushAndInit(PyThreadState *tstate, PyFunctionObject *func, if (frame == NULL) { goto fail; } - _PyFrame_InitializeSpecials(frame, func, locals, code); + _PyFrame_Initialize(frame, func, locals, code, 0); PyObject **localsarray = &frame->localsplus[0]; - for (int i = 0; i < code->co_nlocalsplus; i++) { - localsarray[i] = NULL; - } if (initialize_locals(tstate, func, localsarray, args, argcount, kwnames)) { assert(frame->owner != FRAME_OWNED_BY_GENERATOR); _PyEvalFrameClearAndPop(tstate, frame); |