[Python-checkins] r46873 - python/trunk/Modules/_bsddb.c

neal.norwitz python-checkins at python.org
Mon Jun 12 04:05:56 CEST 2006


Author: neal.norwitz
Date: Mon Jun 12 04:05:55 2006
New Revision: 46873

Modified:
   python/trunk/Modules/_bsddb.c
Log:
Cleanup Py_ssize_t a little (get rid of second #ifdef)

Modified: python/trunk/Modules/_bsddb.c
==============================================================================
--- python/trunk/Modules/_bsddb.c	(original)
+++ python/trunk/Modules/_bsddb.c	Mon Jun 12 04:05:55 2006
@@ -103,7 +103,8 @@
 
 
 #if (PY_VERSION_HEX < 0x02050000)
-#define Py_ssize_t      int
+typedef int Py_ssize_t;
+typedef inquiry lenfunc;
 #endif
 
 #ifdef WITH_THREAD
@@ -5153,11 +5154,7 @@
 
 
 static PyMappingMethods DB_mapping = {
-#if (PY_VERSION_HEX < 0x02050000)
         (inquiry)DB_length,          /*mp_length*/
-#else
-        (lenfunc)DB_length,          /*mp_length*/
-#endif
         (binaryfunc)DB_subscript,    /*mp_subscript*/
         (objobjargproc)DB_ass_sub,   /*mp_ass_subscript*/
 };


More information about the Python-checkins mailing list