Skip to content

Commit

Permalink
Stackless issue python#133: make the fast-call functions Stackless aw…
Browse files Browse the repository at this point in the history
…are.

Add Stackless support to call_function_tail().
  • Loading branch information
Anselm Kruis committed Oct 21, 2017
1 parent addabb8 commit 5ab9250
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Objects/abstract.c
Original file line number Diff line number Diff line change
Expand Up @@ -2308,12 +2308,14 @@ call_function_tail(PyObject *callable, PyObject *args)
if (args == NULL)
return NULL;

STACKLESS_PROMOTE_ALL();
if (!PyTuple_Check(args)) {
result = _PyObject_FastCall(callable, &args, 1, NULL);
}
else {
result = PyObject_Call(callable, args, NULL);
}
STACKLESS_ASSERT();

Py_DECREF(args);
return result;
Expand Down

0 comments on commit 5ab9250

Please sign in to comment.