added PyTuple_GET_SIZE macro

This commit is contained in:
Barry Warsaw 1997-01-06 22:44:27 +00:00
parent accfb849f9
commit 9c5494a1b9
1 changed files with 1 additions and 0 deletions

View File

@ -69,6 +69,7 @@ extern int _PyTuple_Resize Py_PROTO((PyObject **, int, int));
/* Macro, trading safety for speed */
#define PyTuple_GET_ITEM(op, i) (((PyTupleObject *)(op))->ob_item[i])
#define PyTuple_GET_SIZE(op) (((PyTupleObject *)(op))->ob_size)
/* Macro, *only* to be used to fill in brand new tuples */
#define PyTuple_SET_ITEM(op, i, v) (((PyTupleObject *)(op))->ob_item[i] = v)