diff options
Diffstat (limited to 'Python')
-rw-r--r-- | Python/ceval.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index 091b0eb..1cf7246 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -2650,13 +2650,10 @@ handle_eval_breaker: } TARGET(BUILD_TUPLE) { - PyObject *tup = PyTuple_New(oparg); + STACK_SHRINK(oparg); + PyObject *tup = _PyTuple_FromArraySteal(stack_pointer, oparg); if (tup == NULL) goto error; - while (--oparg >= 0) { - PyObject *item = POP(); - PyTuple_SET_ITEM(tup, oparg, item); - } PUSH(tup); DISPATCH(); } |