I want to do something along the lines of
static PyObject* printArgs(PyObject* self, PyObject* args) {
PyObject * oarg1 = NULL;
PyArg_ParseTuple(args,"O",&oarg1);
return -- magic --
}
Such that calling modulename.printArgs(a) returns 'a'.
Is this possible? The best I could think of is looking through locals() for a variable that points to whatever I got in args, but if there's more than one name for the value I could get the wrong name.