----------------------------------------
> > No one's undefying PY_SSIZE_T_CLEAN in Python.h. Why? =)
> >
> > There are two different functions one for int length and the other for
> > Py_ssize_t. We define PY_SSIZE_T_CLEAN and that would work with implicit
> > linking (through linker flags, -lpython), because preprocessor
> > conditionally replaces one for the other in modsupport.h, but we need to
> > handle that ourselves with explicit linking, namely dlsym
> > _PyArg_ParseTuple_SizeT instead of PyArg_ParseTuple from libpython.so.
>
> Yes. But you must do this or your patch just adds a bunch of conditions
>
> #if 0 /* Originally #ifndef PY_SSIZE_T_CLEAN */
> /* Import int function variants */
> #else
> /* Import Py_ssize_t function variants */
> #endif
> . Don’t you think having “#if 0”-like conditions is strange? You should
> undefine PY_SSIZE_T_CLEAN based on some conditions, remove one of the
> branches or replace “#ifndef” with what makes more sense.
Yes, Having an if 0 is strange, but I didn't think it was really worth
commenting on since I don't think this is the correct patch anyway. I'm still
trying to understand why he's seeing different compile results than I am,
especially since we're on the ostensibly the same setup.
Am more interested to hear from Maxim why his compile isn't already making the
correct defines, as mine is here.
Thanks,
Sean
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php