Repost : 64 Bit Integer support

php.internals

l0t3k

22 years ago
Question : is there any one of the supported platforms that dont support a 64 bit integer type. i'm not referring to the native int size. for one i can think of Windows 95/98. i'm porting a library and i need to know this so i can determine how to proceed. l0t3k

Wez Furlong

22 years ago
64 bit integer support is really a function of the compiler, not the OS. The windows compiler certainly does support a 64 bit integer type (INT64 iirc). There is probably a configure check somewhere (the bundled mysql client library from 4.3 branch comes to mind) that you can use to make the decision on 64 bit support. --Wez. ----- Original Message ----- From: "l0t3k" <cshmoove@bellsouth.net> To: <internals@lists.php.net> Sent: Thursday, November 06, 2003 1:58 AM Subject: [PHP-DEV] Repost : 64 Bit Integer support

l0t3k

22 years ago
thanks, wez
> There is probably a configure check somewhere (the bundled mysql client > library from 4.3 branch comes to mind) that you can use to make the
decision
> on 64 bit support.
my concern is not the configure check, per se. im just concerned that having the extension depend on 64bit support would eliminate a significant supported platform. as i current only have access to MSVC and gcc, i wanted to do a quick shout to see if someone knew offhand which of the popular compilers would have an issue. l0t3k p.s.. its a largish codebase with 2 developers, so i wouldnt want to simultanously support a 64bit and a 32bit branch.

Michael Walter

22 years ago
Maybe something like that could help you: #define HAS_INT64_PRIMITIVE #ifdef MSVC #define int64_t __int64 #elif ... #else typedef struct int64_t_ { int32_t a, b; } int64_t; #undef HAS_INT64_PRIMITIVE #endif - Michael