[Python-Dev] Baffled by PyArg_ParseTupleAndKeywords modification
Tim Peters
tim.peters at gmail.com
Fri Feb 10 18:19:01 CET 2006
More information about the Python-Dev mailing list
Fri Feb 10 18:19:01 CET 2006
- Previous message: [Python-Dev] Baffled by PyArg_ParseTupleAndKeywords modification
- Next message: [Python-Dev] Baffled by PyArg_ParseTupleAndKeywords modification
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
[Jeremy Hylton]
> ...
> I admit that I'm also puzzled by Jack's specific question. I don't
> understand why an array passed to PyArg_ParseTupleAndKeywords() would
> need to be declared as const. I observed the problem in my initial
> changes but didn't think very hard about the cause of the problem.
> Perhaps someone with better C/C++ standards chops can explain.
Oh, who cares? I predict "Jack's problem" would go away if we changed
the declaration of PyArg_ParseTupleAndKeywords to what you intended
<wink> to begin with:
PyAPI_FUNC(int) PyArg_ParseTupleAndKeywords(PyObject *, PyObject *,
const char *, const
char * const *, ...);
That is, declare the keywords argument as a pointer to const pointer
to const char, rather than the current pointer to pointer to const
char.
How about someone on a Linux box try that with gcc, and check it in if
it solves Jack's problem (meaning that gcc stops whining about the
original spelling of his original example).
- Previous message: [Python-Dev] Baffled by PyArg_ParseTupleAndKeywords modification
- Next message: [Python-Dev] Baffled by PyArg_ParseTupleAndKeywords modification
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-Dev mailing list