emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r104524: Update nt/inc/stdint.h for P


From: Eli Zaretskii
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r104524: Update nt/inc/stdint.h for PTRDIFF_MAX.
Date: Tue, 07 Jun 2011 15:34:09 +0300
User-agent: Bazaar (2.3.1)

------------------------------------------------------------
revno: 104524
committer: Eli Zaretskii <address@hidden>
branch nick: trunk
timestamp: Tue 2011-06-07 15:34:09 +0300
message:
  Update nt/inc/stdint.h for PTRDIFF_MAX.
  
   nt/inc/stdint.h (INT32_MAX, INT64_MAX, INTPTR_MAX, PTRDIFF_MAX)
   [!__GNUC__]: New macros.
modified:
  nt/ChangeLog
  nt/inc/stdint.h
=== modified file 'nt/ChangeLog'
--- a/nt/ChangeLog      2011-05-28 22:39:39 +0000
+++ b/nt/ChangeLog      2011-06-07 12:34:09 +0000
@@ -1,3 +1,8 @@
+2011-06-07  Eli Zaretskii  <address@hidden>
+
+       * inc/stdint.h (INT32_MAX, INT64_MAX, INTPTR_MAX, PTRDIFF_MAX)
+       [!__GNUC__}: New macros.
+
 2011-05-28  Paul Eggert  <address@hidden>
 
        Use 'inline', not 'INLINE'.

=== modified file 'nt/inc/stdint.h'
--- a/nt/inc/stdint.h   2011-05-06 12:09:08 +0000
+++ b/nt/inc/stdint.h   2011-06-07 12:34:09 +0000
@@ -28,14 +28,20 @@
    stdint.h is not available, e.g. Microsoft Visual Studio.  */
 
 typedef unsigned int uint32_t;
+#define INT32_MAX 2147483647
+/* "i64" is the non-standard suffix used by MSVC for 64-bit constants.  */
+#define INT64_MAX 9223372036854775807i64
 
 #ifdef _WIN64
   typedef __int64 intptr_t;
+#define INTPTR_MAX INT64_MAX
 #else
   typedef int intptr_t;
+#define INTPTR_MAX INT32_MAX
 #endif
 
 #define uintmax_t unsigned __int64
+#define PTRDIFF_MAX INTPTR_MAX
 
 #endif /* !__GNUC__ */
 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]