[MLton-commit] r7108
Matthew Fluet
fluet at mlton.org
Wed Jun 10 20:22:50 PDT 2009
Quell gcc 4.4 warnings.
----------------------------------------------------------------------
U mlton/trunk/runtime/basis/Real/class.c
U mlton/trunk/runtime/bytecode/interpret.c
----------------------------------------------------------------------
Modified: mlton/trunk/runtime/basis/Real/class.c
===================================================================
--- mlton/trunk/runtime/basis/Real/class.c 2009-06-11 03:22:47 UTC (rev 7107)
+++ mlton/trunk/runtime/basis/Real/class.c 2009-06-11 03:22:50 UTC (rev 7108)
@@ -1,12 +1,12 @@
#include "platform.h"
-#if HAS_FPCLASSIFY
+#if defined (HAS_FPCLASSIFY) && HAS_FPCLASSIFY
C_Int_t Real32_class (Real32_t f) {
return fpclassify (f);
}
-#elif HAS_FPCLASSIFY32
+#elif defined (HAS_FPCLASSIFY32) && HAS_FPCLASSIFY32
C_Int_t Real32_class (Real32_t f) {
return fpclassify32 (f);
@@ -77,13 +77,13 @@
#endif
-#if HAS_FPCLASSIFY
+#if defined (HAS_FPCLASSIFY) && HAS_FPCLASSIFY
C_Int_t Real64_class (Real64_t d) {
return fpclassify (d);
}
-#elif HAS_FPCLASSIFY64
+#elif defined (HAS_FPCLASSIFY64) && HAS_FPCLASSIFY64
C_Int_t Real64_class (Real64_t d) {
return fpclassify64 (d);
Modified: mlton/trunk/runtime/bytecode/interpret.c
===================================================================
--- mlton/trunk/runtime/bytecode/interpret.c 2009-06-11 03:22:47 UTC (rev 7107)
+++ mlton/trunk/runtime/bytecode/interpret.c 2009-06-11 03:22:50 UTC (rev 7108)
@@ -1,4 +1,5 @@
-/* Copyright (C) 2004-2008 Henry Cejtin, Matthew Fluet, Suresh
+/* Copyright (C) 2009 Matthew Fluet.
+ * Copyright (C) 2004-2008 Henry Cejtin, Matthew Fluet, Suresh
* Jagannathan, and Stephen Weeks.
*
* MLton is released under a BSD-style license.
@@ -450,19 +451,19 @@
#undef FlushStackTop
#define CacheFrontier() \
do { \
- frontier = gcState.frontier; \
+ frontier = (Pointer)(gcState.frontier); \
} while (0)
#define CacheStackTop() \
do { \
- stackTop = gcState.stackTop; \
+ stackTop = (Pointer)(gcState.stackTop); \
} while (0)
#define FlushFrontier() \
do { \
- gcState.frontier = frontier; \
+ gcState.frontier = (pointer)frontier; \
} while (0)
#define FlushStackTop() \
do { \
- gcState.stackTop = stackTop; \
+ gcState.stackTop = (pointer)stackTop; \
} while (0)
#define disp(ty,ty2,fmt) \
@@ -591,7 +592,7 @@
goto mainLoop;
}
case opcodeSym (Raise):
- maybe StackTop = gcState.stackBottom + gcState.exnStack;
+ maybe StackTop = (Pointer)(gcState.stackBottom + gcState.exnStack);
// fall through to Return.
case opcodeSym (Return):
Goto (*(Label*)(StackTop - sizeof (Label)));
More information about the MLton-commit
mailing list