The INT32_MIN_BROKEN and INT64_MIN_BROKEN tweaks needs
Jarkko Hietaniemi [Tue, 19 Jun 2001 10:52:25 +0000 (10:52 +0000)]
to happen right after the inclusion of <inttypes.h>,
from Edward Moy.

p4raw-id: //depot/perl@10716

handy.h
perl.h

diff --git a/handy.h b/handy.h
index 76cbf2e..c2bfe1e 100644 (file)
--- a/handy.h
+++ b/handy.h
@@ -116,6 +116,14 @@ Null SV pointer.
 
 #ifdef I_INTTYPES /* e.g. Linux has int64_t without <inttypes.h> */
 #   include <inttypes.h>
+#   ifdef INT32_MIN_BROKEN
+#       undef  INT32_MIN
+#       define INT32_MIN (-2147483647-1)
+#   endif
+#   ifdef INT64_MIN_BROKEN
+#       undef  INT64_MIN
+#       define INT64_MIN (-9223372036854775807LL-1)
+#   endif
 #endif
 
 typedef I8TYPE I8;
diff --git a/perl.h b/perl.h
index a0405d1..4c82ca7 100644 (file)
--- a/perl.h
+++ b/perl.h
@@ -1082,16 +1082,6 @@ int sockatmark(int);
 typedef IVTYPE IV;
 typedef UVTYPE UV;
 
-#ifdef INT32_MIN_BROKEN
-#  undef  INT32_MIN
-#  define INT32_MIN (-2147483647-1)
-#endif
-
-#ifdef INT64_MIN_BROKEN
-#  undef  INT64_MIN
-#  define INT64_MIN (-9223372036854775807LL-1)
-#endif
-
 #if defined(USE_64_BIT_INT) && defined(HAS_QUAD)
 #  if QUADKIND == QUAD_IS_INT64_T && defined(INT64_MAX)
 #    define IV_MAX INT64_MAX