Luke Kenneth Casson Leighton <l...@lkcl.net> added the comment: .... hmmm... noo, it's already #defined to 0x7fffffffL in both PC/pyconfig.h _and_ in /usr/include/wine/msvcrt/limits.h
so .... this works (Include/pyports.h) #ifdef __WINE__ /* weird: you have to typecast 0x7fffffffL to long */ #undef LONG_MAX #undef LONG_MIN #define LONG_MAX ((long)0x7FFFFFFFL) #define LONG_MIN ((long)(-LONG_MAX-1)) #else #ifndef LONG_MAX #if SIZEOF_LONG == 4 #define LONG_MAX 0X7FFFFFFFL #elif SIZEOF_LONG == 8 #define LONG_MAX 0X7FFFFFFFFFFFFFFFL #else #error "could not set LONG_MAX in pyport.h" #endif #endif #ifndef LONG_MIN #define LONG_MIN (-LONG_MAX-1) #endif #endif /* __WINE__ */ _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue4880> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com