kinda of silly???
Martin von Loewis
loewis at informatik.hu-berlin.de
Sun Jul 9 06:09:42 EDT 2000
"Arinté" <shouldbe at message.com> writes:
> When you are embedding python in a c++ app, all arguments sent from python
> to c++ in should function call should be parsed with PyArg_ParseTuple. Is
> that statement correct?
>
> I could have swore someone a while back told me other wise.
While this is the common approach, it is by no means the only
one. Python simply passes a tuple object to the C function. It is then
up to that function to analyse it. PyArg_ParseTuple is convenient for
fixed-number varying-type functions, whereas, say, PyTuple_GetItem
would be required for more complex cases of varargs functions.
Regards,
Martin
More information about the Python-list
mailing list