[MLton-commit] r6533

Ville Laurikari ville at mlton.org
Mon Apr 7 00:17:52 PDT 2008


Define UINTPTR_MAX for Solaris 8 and older.

----------------------------------------------------------------------

U   mlton/trunk/runtime/platform/solaris.h

----------------------------------------------------------------------

Modified: mlton/trunk/runtime/platform/solaris.h
===================================================================
--- mlton/trunk/runtime/platform/solaris.h	2008-04-07 06:56:07 UTC (rev 6532)
+++ mlton/trunk/runtime/platform/solaris.h	2008-04-07 07:17:50 UTC (rev 6533)
@@ -110,3 +110,14 @@
 typedef uint32_t socklen_t;
 #endif /* defined(_XPG4_2) && !defined(_XPG5) && !defined(_LP64) */
 #endif /* _SOCKLEN_T */
+
+/* Solaris 8 and older do not define a value for UINTPTR_MAX, so
+   we redefine it with a value. */
+#ifdef UINTPTR_MAX
+#undef UINTPTR_MAX
+#if defined(_LP64) || defined(_I32LPx)
+#define UINTPTR_MAX     UINT64_MAX
+#else
+#define UINTPTR_MAX     UINT32_MAX
+#endif
+#endif




More information about the MLton-commit mailing list