[MLton-commit] r5744

Matthew Fluet fluet at mlton.org
Sun Jul 8 21:51:04 PDT 2007


Eliminate some gcc warnings with C files produced by C-codegen
----------------------------------------------------------------------

U   mlton/trunk/include/c-chunk.h
U   mlton/trunk/mlton/backend/backend.fun
U   mlton/trunk/mlton/backend/machine.fun
U   mlton/trunk/mlton/codegen/c-codegen/c-codegen.fun
U   mlton/trunk/runtime/basis/Real/Math-fns.h
U   mlton/trunk/runtime/basis/Word/Word-ops.h
U   mlton/trunk/runtime/basis-ffi.h
U   mlton/trunk/runtime/bytecode/interpret.c
U   mlton/trunk/runtime/gen/basis-ffi.def
U   mlton/trunk/runtime/gen/basis-ffi.h
U   mlton/trunk/runtime/platform.h

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

Modified: mlton/trunk/include/c-chunk.h
===================================================================
--- mlton/trunk/include/c-chunk.h	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/include/c-chunk.h	2007-07-09 04:51:00 UTC (rev 5744)
@@ -113,8 +113,8 @@
 
 #define ChunkSwitch(n)                                                  \
                 if (DEBUG_CCODEGEN)                                     \
-                        fprintf (stderr, "%s:%d: entering chunk %d  l_nextFun = %d\n",  \
-                                        __FILE__, __LINE__, n, l_nextFun);      \
+                        fprintf (stderr, "%s:%d: entering chunk %d  l_nextFun = %d\n", \
+                                        __FILE__, __LINE__, n, (int)l_nextFun); \
                 CacheFrontier();                                        \
                 CacheStackTop();                                        \
                 while (1) {                                             \
@@ -174,7 +174,7 @@
                 l_nextFun = *(uintptr_t*)(StackTop - sizeof(void*));            \
                 if (DEBUG_CCODEGEN)                                             \
                         fprintf (stderr, "%s:%d: Return()  l_nextFun = %d\n",   \
-                                        __FILE__, __LINE__, l_nextFun);         \
+                                        __FILE__, __LINE__, (int)l_nextFun);    \
                 goto top;                                                       \
         } while (0)
 
@@ -206,6 +206,12 @@
 #ifndef MLTON_CODEGEN_WORDSQUOTREM
 #define MLTON_CODEGEN_WORDSQUOTREM(func) 
 #endif
+/* Declare memcpy, since <string.h> isn't included.
+ */
+#ifndef MLTON_CODEGEN_MAMCPY
+#define MLTON_CODEGEN_MEMCPY(decl)
+#endif
+MLTON_CODEGEN_MEMCPY(void * memcpy(void *, const void*, size_t);)
 #include "basis-ffi.h"
 #include "basis/coerce.h"
 #include "basis/cpointer.h"

Modified: mlton/trunk/mlton/backend/backend.fun
===================================================================
--- mlton/trunk/mlton/backend/backend.fun	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/mlton/backend/backend.fun	2007-07-09 04:51:00 UTC (rev 5744)
@@ -558,11 +558,11 @@
                                    (Bytes.+ (handlerOffset (), Runtime.labelSize ()))),
                                   WordSize.cpointer ())))),
                        dst = SOME tmp,
-                       prim = Prim.wordAdd (WordSize.cpointer ())},
+                       prim = Prim.cpointerAdd},
                       M.Statement.PrimApp
                       {args = Vector.new2 (tmp, stackBottomOp),
                        dst = SOME exnStackOp,
-                       prim = Prim.wordSub (WordSize.cpointer ())})
+                       prim = Prim.cpointerDiff})
                   end
              | SetExnStackSlot =>
                   (* ExnStack = *(uint* )(stackTop + offset);   *)

Modified: mlton/trunk/mlton/backend/machine.fun
===================================================================
--- mlton/trunk/mlton/backend/machine.fun	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/mlton/backend/machine.fun	2007-07-09 04:51:00 UTC (rev 5744)
@@ -403,10 +403,10 @@
              PrimApp {args = Vector.new2 (Frontier,
                                           bytes (Runtime.headerSize ())),
                       dst = SOME dst,
-                      prim = Prim.wordAdd (WordSize.cpointer ())},
+                      prim = Prim.cpointerAdd},
              PrimApp {args = Vector.new2 (Frontier, bytes size),
                       dst = SOME Frontier,
-                      prim = Prim.wordAdd (WordSize.cpointer ())})
+                      prim = Prim.cpointerAdd})
          end
 
       fun foldOperands (s, ac, f) =

Modified: mlton/trunk/mlton/codegen/c-codegen/c-codegen.fun
===================================================================
--- mlton/trunk/mlton/codegen/c-codegen/c-codegen.fun	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/mlton/codegen/c-codegen/c-codegen.fun	2007-07-09 04:51:00 UTC (rev 5744)
@@ -632,7 +632,7 @@
                                        C.bytes offset]]
              | Cast (z, ty) => concat ["(", Type.toC ty, ")", toString z]
              | Contents {oper, ty} => contents (ty, toString oper)
-             | File => "__FILE__"
+             | File => "(CPointer)(__FILE__)"
              | Frontier => "Frontier"
              | GCState => "GCState"
              | Global g =>

Modified: mlton/trunk/runtime/basis/Real/Math-fns.h
===================================================================
--- mlton/trunk/runtime/basis/Real/Math-fns.h	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/runtime/basis/Real/Math-fns.h	2007-07-09 04:51:00 UTC (rev 5744)
@@ -1,8 +1,4 @@
 
-#ifndef MLTON_CODEGEN_MATHFN
-#define MLTON_CODEGEN_MATHFN(decl) 
-#endif
-
 #define unaryReal(g, h)                                         \
   MLTON_CODEGEN_MATHFN(Real64_t h(Real64_t x);)                 \
   MLTON_CODEGEN_STATIC_INLINE                                   \

Modified: mlton/trunk/runtime/basis/Word/Word-ops.h
===================================================================
--- mlton/trunk/runtime/basis/Word/Word-ops.h	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/runtime/basis/Word/Word-ops.h	2007-07-09 04:51:00 UTC (rev 5744)
@@ -1,8 +1,4 @@
 
-#ifndef MLTON_CODEGEN_WORDSQUOTREM
-#define MLTON_CODEGEN_WORDSQUOTREM(func) func
-#endif
-
 #define binary(kind, name, op)                                          \
   MLTON_CODEGEN_STATIC_INLINE                                           \
   Word##kind Word##kind##_##name (Word##kind w1, Word##kind w2) {       \

Modified: mlton/trunk/runtime/basis-ffi.h
===================================================================
--- mlton/trunk/runtime/basis-ffi.h	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/runtime/basis-ffi.h	2007-07-09 04:51:00 UTC (rev 5744)
@@ -993,8 +993,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_mul(Int16_t,Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS16_mulCheckOverflows(Int16_t,Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS16_negCheckOverflows(Int16_t);
-MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_quot(Int16_t,Int16_t);
-MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_rem(Int16_t,Int16_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int16_t WordS16_quot(Int16_t,Int16_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int16_t WordS16_rem(Int16_t,Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS16_rndToReal32(Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS16_rndToReal64(Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_rshift(Int16_t,Word32_t);
@@ -1011,8 +1011,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_mul(Int32_t,Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS32_mulCheckOverflows(Int32_t,Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS32_negCheckOverflows(Int32_t);
-MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_quot(Int32_t,Int32_t);
-MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_rem(Int32_t,Int32_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int32_t WordS32_quot(Int32_t,Int32_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int32_t WordS32_rem(Int32_t,Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS32_rndToReal32(Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS32_rndToReal64(Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_rshift(Int32_t,Word32_t);
@@ -1029,8 +1029,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_mul(Int64_t,Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS64_mulCheckOverflows(Int64_t,Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS64_negCheckOverflows(Int64_t);
-MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_quot(Int64_t,Int64_t);
-MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_rem(Int64_t,Int64_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int64_t WordS64_quot(Int64_t,Int64_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int64_t WordS64_rem(Int64_t,Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS64_rndToReal32(Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS64_rndToReal64(Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_rshift(Int64_t,Word32_t);
@@ -1047,8 +1047,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_mul(Int8_t,Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS8_mulCheckOverflows(Int8_t,Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS8_negCheckOverflows(Int8_t);
-MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_quot(Int8_t,Int8_t);
-MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_rem(Int8_t,Int8_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int8_t WordS8_quot(Int8_t,Int8_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int8_t WordS8_rem(Int8_t,Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS8_rndToReal32(Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS8_rndToReal64(Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_rshift(Int8_t,Word32_t);

Modified: mlton/trunk/runtime/bytecode/interpret.c
===================================================================
--- mlton/trunk/runtime/bytecode/interpret.c	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/runtime/bytecode/interpret.c	2007-07-09 04:51:00 UTC (rev 5744)
@@ -9,7 +9,6 @@
 #ifndef MLTON_CODEGEN_STATIC_INLINE
 #define MLTON_CODEGEN_STATIC_INLINE static inline
 #endif
-#include "platform.h"
 
 /* No need to declare inlined math functions, since <math.h> comes
  * with "platform.h".
@@ -24,6 +23,12 @@
 #ifndef MLTON_CODEGEN_WORDSQUOTREM
 #define MLTON_CODEGEN_WORDSQUOTREM(func) func
 #endif
+/* No need to declare memcpy, since <string.h> comes with platform.h.
+ */
+#ifndef MLTON_CODEGEN_MATHFN
+#define MLTON_CODEGEN_MEMCPY(decl)
+#endif
+#include "platform.h"
 #include "c-chunk.h"    // c-chunk.h must come before opcode.h because it
                         // redefines some opcode symbols
 

Modified: mlton/trunk/runtime/gen/basis-ffi.def
===================================================================
--- mlton/trunk/runtime/gen/basis-ffi.def	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/runtime/gen/basis-ffi.def	2007-07-09 04:51:00 UTC (rev 5744)
@@ -990,8 +990,8 @@
 WordS16.mul = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t * Int16.t -> Int16.t
 WordS16.mulCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t * Int16.t -> Bool.t
 WordS16.negCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t -> Bool.t
-WordS16.quot = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t * Int16.t -> Int16.t
-WordS16.rem = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t * Int16.t -> Int16.t
+WordS16.quot = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int16.t * Int16.t -> Int16.t
+WordS16.rem = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int16.t * Int16.t -> Int16.t
 WordS16.rndToReal32 = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t -> Real32.t
 WordS16.rndToReal64 = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t -> Real64.t
 WordS16.rshift = _import MLTON_CODEGEN_STATIC_INLINE : Int16.t * Word32.t -> Int16.t
@@ -1008,8 +1008,8 @@
 WordS32.mul = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t * Int32.t -> Int32.t
 WordS32.mulCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t * Int32.t -> Bool.t
 WordS32.negCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t -> Bool.t
-WordS32.quot = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t * Int32.t -> Int32.t
-WordS32.rem = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t * Int32.t -> Int32.t
+WordS32.quot = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int32.t * Int32.t -> Int32.t
+WordS32.rem = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int32.t * Int32.t -> Int32.t
 WordS32.rndToReal32 = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t -> Real32.t
 WordS32.rndToReal64 = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t -> Real64.t
 WordS32.rshift = _import MLTON_CODEGEN_STATIC_INLINE : Int32.t * Word32.t -> Int32.t
@@ -1026,8 +1026,8 @@
 WordS64.mul = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t * Int64.t -> Int64.t
 WordS64.mulCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t * Int64.t -> Bool.t
 WordS64.negCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t -> Bool.t
-WordS64.quot = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t * Int64.t -> Int64.t
-WordS64.rem = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t * Int64.t -> Int64.t
+WordS64.quot = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int64.t * Int64.t -> Int64.t
+WordS64.rem = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int64.t * Int64.t -> Int64.t
 WordS64.rndToReal32 = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t -> Real32.t
 WordS64.rndToReal64 = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t -> Real64.t
 WordS64.rshift = _import MLTON_CODEGEN_STATIC_INLINE : Int64.t * Word32.t -> Int64.t
@@ -1044,8 +1044,8 @@
 WordS8.mul = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t * Int8.t -> Int8.t
 WordS8.mulCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t * Int8.t -> Bool.t
 WordS8.negCheckOverflows = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t -> Bool.t
-WordS8.quot = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t * Int8.t -> Int8.t
-WordS8.rem = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t * Int8.t -> Int8.t
+WordS8.quot = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int8.t * Int8.t -> Int8.t
+WordS8.rem = _import MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) : Int8.t * Int8.t -> Int8.t
 WordS8.rndToReal32 = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t -> Real32.t
 WordS8.rndToReal64 = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t -> Real64.t
 WordS8.rshift = _import MLTON_CODEGEN_STATIC_INLINE : Int8.t * Word32.t -> Int8.t

Modified: mlton/trunk/runtime/gen/basis-ffi.h
===================================================================
--- mlton/trunk/runtime/gen/basis-ffi.h	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/runtime/gen/basis-ffi.h	2007-07-09 04:51:00 UTC (rev 5744)
@@ -993,8 +993,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_mul(Int16_t,Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS16_mulCheckOverflows(Int16_t,Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS16_negCheckOverflows(Int16_t);
-MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_quot(Int16_t,Int16_t);
-MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_rem(Int16_t,Int16_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int16_t WordS16_quot(Int16_t,Int16_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int16_t WordS16_rem(Int16_t,Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS16_rndToReal32(Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS16_rndToReal64(Int16_t);
 MLTON_CODEGEN_STATIC_INLINE Int16_t WordS16_rshift(Int16_t,Word32_t);
@@ -1011,8 +1011,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_mul(Int32_t,Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS32_mulCheckOverflows(Int32_t,Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS32_negCheckOverflows(Int32_t);
-MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_quot(Int32_t,Int32_t);
-MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_rem(Int32_t,Int32_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int32_t WordS32_quot(Int32_t,Int32_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int32_t WordS32_rem(Int32_t,Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS32_rndToReal32(Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS32_rndToReal64(Int32_t);
 MLTON_CODEGEN_STATIC_INLINE Int32_t WordS32_rshift(Int32_t,Word32_t);
@@ -1029,8 +1029,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_mul(Int64_t,Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS64_mulCheckOverflows(Int64_t,Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS64_negCheckOverflows(Int64_t);
-MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_quot(Int64_t,Int64_t);
-MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_rem(Int64_t,Int64_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int64_t WordS64_quot(Int64_t,Int64_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int64_t WordS64_rem(Int64_t,Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS64_rndToReal32(Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS64_rndToReal64(Int64_t);
 MLTON_CODEGEN_STATIC_INLINE Int64_t WordS64_rshift(Int64_t,Word32_t);
@@ -1047,8 +1047,8 @@
 MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_mul(Int8_t,Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS8_mulCheckOverflows(Int8_t,Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Bool_t WordS8_negCheckOverflows(Int8_t);
-MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_quot(Int8_t,Int8_t);
-MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_rem(Int8_t,Int8_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int8_t WordS8_quot(Int8_t,Int8_t);
+MLTON_CODEGEN_WORDSQUOTREM(MLTON_CODEGEN_STATIC_INLINE) Int8_t WordS8_rem(Int8_t,Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Real32_t WordS8_rndToReal32(Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Real64_t WordS8_rndToReal64(Int8_t);
 MLTON_CODEGEN_STATIC_INLINE Int8_t WordS8_rshift(Int8_t,Word32_t);

Modified: mlton/trunk/runtime/platform.h
===================================================================
--- mlton/trunk/runtime/platform.h	2007-07-08 20:21:14 UTC (rev 5743)
+++ mlton/trunk/runtime/platform.h	2007-07-09 04:51:00 UTC (rev 5744)
@@ -113,6 +113,12 @@
 #ifndef MLTON_CODEGEN_STATIC_INLINE
 #define MLTON_CODEGEN_STATIC_INLINE /*static inline*/
 #endif
+#ifndef MLTON_CODEGEN_MATHFN
+#define MLTON_CODEGEN_MATHFN(decl) 
+#endif
+#ifndef MLTON_CODEGEN_WORDSQUOTREM
+#define MLTON_CODEGEN_WORDSQUOTREM(func) func
+#endif
 #include "basis-ffi.h"
 
 #include "gc.h"




More information about the MLton-commit mailing list