Speed-up the joiner call by avoiding Py_BuildValue().

This commit is contained in:
Raymond Hettinger 2004-02-27 10:30:49 +00:00
parent 2460c62152
commit bc72c5ae8b

View File

@ -436,7 +436,11 @@ O_writelines(Oobject *self, PyObject *args) {
if (PyObject_Size(args) < 0) return NULL;
tmp = PyObject_CallFunction(joiner, "O", args);
args = PyTuple_Pack(1, args);
if (args == NULL)
return NULL;
tmp = PyObject_Call(joiner, args, NULL);
Py_DECREF(args);
UNLESS (tmp) return NULL;
args = PyTuple_Pack(1, tmp);