Mercurial > cpython-lru_cache-weakref
diff Include/tupleobject.h @ 30682:473f4e2959a8 legacy-trunk
Extended tuple's C API to include a new function, PyTuple_Pack() that is
useful for rapidly building argument tuples without having to invoke the
more sophisticated machinery of Py_BuildValue().
| author | Raymond Hettinger <python@rcn.com> |
|---|---|
| date | Sun, 12 Oct 2003 18:24:34 +0000 |
| parents | c1eb668525e1 |
| children | 60c60dc75c77 |
line wrap: on
line diff
--- a/Include/tupleobject.h Sun Oct 12 17:37:01 2003 +0000 +++ b/Include/tupleobject.h Sun Oct 12 18:24:34 2003 +0000 @@ -35,6 +35,7 @@ PyAPI_FUNC(int) PyTuple_SetItem(PyObject *, int, PyObject *); PyAPI_FUNC(PyObject *) PyTuple_GetSlice(PyObject *, int, int); PyAPI_FUNC(int) _PyTuple_Resize(PyObject **, int); +PyAPI_FUNC(PyObject *) PyTuple_Pack(int, ...); /* Macro, trading safety for speed */ #define PyTuple_GET_ITEM(op, i) (((PyTupleObject *)(op))->ob_item[i])
