summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorThomas Heller <theller@ctypes.org>2007-10-25 19:47:32 (GMT)
committerThomas Heller <theller@ctypes.org>2007-10-25 19:47:32 (GMT)
commit469b2a52cdeb861311d3dada9aadb75cfd652f23 (patch)
tree268749660ff10ef44909f8e84b0b74c451239e52 /Modules
parent6e183f8f440af90dd3470efc4193fd868d3b1537 (diff)
downloadcpython-469b2a52cdeb861311d3dada9aadb75cfd652f23.zip
cpython-469b2a52cdeb861311d3dada9aadb75cfd652f23.tar.gz
cpython-469b2a52cdeb861311d3dada9aadb75cfd652f23.tar.bz2
ffi_type_longdouble may be already #defined.
See issue 1324.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/_ctypes/cfield.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/Modules/_ctypes/cfield.c b/Modules/_ctypes/cfield.c
index 5f5fd99..77667f5 100644
--- a/Modules/_ctypes/cfield.c
+++ b/Modules/_ctypes/cfield.c
@@ -1753,11 +1753,13 @@ ffi_type ffi_type_sint64 = { 8, LONG_LONG_ALIGN, FFI_TYPE_SINT64 };
ffi_type ffi_type_float = { sizeof(float), FLOAT_ALIGN, FFI_TYPE_FLOAT };
ffi_type ffi_type_double = { sizeof(double), DOUBLE_ALIGN, FFI_TYPE_DOUBLE };
+
+#ifdef ffi_type_longdouble
+#undef ffi_type_longdouble
+#endif
ffi_type ffi_type_longdouble = { sizeof(long double), LONGDOUBLE_ALIGN,
FFI_TYPE_LONGDOUBLE };
-/* ffi_type ffi_type_longdouble */
-
ffi_type ffi_type_pointer = { sizeof(void *), VOID_P_ALIGN, FFI_TYPE_POINTER };
/*---------------- EOF ----------------*/