[Python-checkins] r78255 - python/branches/py3k-cdecimal/Modules/cdecimal/mpdecimal32.h

stefan.krah python-checkins at python.org
Sat Feb 20 18:05:15 CET 2010


Author: stefan.krah
Date: Sat Feb 20 18:05:15 2010
New Revision: 78255

Log:
Accommodate compilers without uint64_t.

Modified:
   python/branches/py3k-cdecimal/Modules/cdecimal/mpdecimal32.h

Modified: python/branches/py3k-cdecimal/Modules/cdecimal/mpdecimal32.h
==============================================================================
--- python/branches/py3k-cdecimal/Modules/cdecimal/mpdecimal32.h	(original)
+++ python/branches/py3k-cdecimal/Modules/cdecimal/mpdecimal32.h	Sat Feb 20 18:05:15 2010
@@ -20,31 +20,19 @@
 #include <assert.h>
 
 
-#define EXTINLINE
-#ifdef _MSC_VER
-  #include "vccompat.h"
-  #ifndef UNUSED
-    #define UNUSED
-  #endif
-  #undef EXTINLINE
-  #define EXTINLINE extern inline
-#else
-  #include <stdint.h>
-  #define __GNUC_STDC_INLINE__
-  #define UNUSED __attribute__((unused))
-#endif
-
-
 /******************************************************************************/
 /*                      Types for 32 bit architectures                        */
 /******************************************************************************/
 
 /* types for modular and base arithmetic */
 #define MPD_UINT_MAX UINT32_MAX
-#define MPD_UUINT_MAX UINT64_MAX
 #define MPD_BITS_PER_UINT 32
 typedef uint32_t mpd_uint_t;  /* unsigned mod type */
+
+#ifndef LEGACY_COMPILER
+#define MPD_UUINT_MAX UINT64_MAX
 typedef uint64_t mpd_uuint_t; /* double width unsigned mod type */
+#endif
 
 /* enable CONFIG_32+ANSI on 64-bit platforms without resorting to -m32 */
 #define MPD_SIZE_MAX UINT32_MAX


More information about the Python-checkins mailing list