On Tue, Jun 10, 2008 at 10:13 AM, Doug Evans <dje@google.com> wrote:
I spent a bit of time trying to figure out what's going on here
(was getting errors regarding missing uintptr_t while trying to compile
an external module with Python 2.4).
pyport.h now includes stdint.h but can we fix up this in Python.h?

/* For uintptr_t, intptr_t */
#include <stddef.h>

I'm guessing removing the inclusion of stddef.h will break something.
It's a bit of a wart (or not) that Python.h includes stdlib.h, stddef.h, et.al.
but pyport.h includes stdint.h (why not just include them all in one place?).

Anyways, to save some confusion for someone trying to track down
a problem in the future, could the above comment be removed?

Okay.  I changed it to /* For size_t? */ in trunk (2.6).

--- Python.h    (revision 64082)
+++ Python.h    (working copy)
@@ -43,8 +43,6 @@
 #include <unistd.h>
-/* For uintptr_t, intptr_t */
 #include <stddef.h>

[I'd suggest rewording it except that I'm not sure exactly what stddef.h
is used for.  Presumably it's size_t but I didn't want to guess.]
Python-Dev mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-dev/greg%40krypto.org