[project @ 2001-10-31 17:00:49 by rrt]
authorrrt <unknown>
Wed, 31 Oct 2001 17:03:12 +0000 (17:03 +0000)
committerrrt <unknown>
Wed, 31 Oct 2001 17:03:12 +0000 (17:03 +0000)
Beginnings of .NET Integer support.

ghc/compiler/prelude/primops.txt.pp
ghc/lib/std/PrelGHC.hi-boot.pp

index 7d6b000..ee64b05 100644 (file)
@@ -1,5 +1,5 @@
 -----------------------------------------------------------------------
--- $Id: primops.txt.pp,v 1.8 2001/10/17 11:26:04 simonpj Exp $
+-- $Id: primops.txt.pp,v 1.9 2001/10/31 17:03:12 rrt Exp $
 --
 -- Primitive Operations
 --
@@ -351,9 +351,15 @@ section "Integer#"
 implemented via the GMP package. An integer is represented as a pair
 consisting of an Int\# representing the number of 'limbs' in use and
 the sign, and a ByteArr\# containing the 'limbs' themselves.  Such pairs
-are returned as unboxed pairs, but must be passed as separate components.}
+are returned as unboxed pairs, but must be passed as separate
+components.
+
+For .NET these operations are implemented by foreign imports, so the
+primops are omitted.}
 ------------------------------------------------------------------------
 
+#ifndef ILX
+
 primop   IntegerAddOp   "plusInteger#" GenPrimOp   
    Int# -> ByteArr# -> Int# -> ByteArr# -> (# Int#, ByteArr# #)
    with commutable = True
@@ -458,6 +464,7 @@ primop   IntegerComplementOp  "complementInteger#" GenPrimOp
    Int# -> ByteArr# -> (# Int#, ByteArr# #)
    with out_of_line = True
 
+#endif /* ILX */
 
 ------------------------------------------------------------------------
 section "Double#"
index d551efc..d478480 100644 (file)
@@ -211,6 +211,9 @@ __export PrelGHC
   ztztzhzh
   decodeDoublezh
 
+-- Integer is implemented by foreign imports on .NET, so no primops
+
+#ifndef ILX
   cmpIntegerzh
   cmpIntegerIntzh
   plusIntegerzh
@@ -244,6 +247,7 @@ __export PrelGHC
   orIntegerzh
   xorIntegerzh
   complementIntegerzh
+#endif
 
   Arrayzh
   ByteArrayzh