X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Flib%2Fstd%2FPrelGHC.hi-boot;h=af92064a0f231cf6650f918e4839a63e97d26167;hb=d042db028daa5e7aeccc32e9b00037acbf2c40ab;hp=a4c5d30acbe11ef1ef20d4309ae804644f5090f0;hpb=449deb80dde91031b86b9cb4fb183696e0139bae;p=ghc-hetmet.git diff --git a/ghc/lib/std/PrelGHC.hi-boot b/ghc/lib/std/PrelGHC.hi-boot index a4c5d30..af92064 100644 --- a/ghc/lib/std/PrelGHC.hi-boot +++ b/ghc/lib/std/PrelGHC.hi-boot @@ -1,23 +1,27 @@ --------------------------------------------------------------------------- --- GHC.hi +-- PrelGHC.hi-boot -- -- This hand-written interface file allows you to bring into scope the -- primitive operations and types that GHC knows about. --------------------------------------------------------------------------- -__interface PrelGHC 2 0 where +__interface "std" PrelGHC 1 0 where __export PrelGHC ZLzmzgZR -- (->) - All -- Pseudo class used for universal quantification CCallable CReturnable -- Magical assert thingy assert + -- constructor tags + tagToEnumzh + getTagzh + dataToTagzh + -- I/O primitives RealWorld realWorldzh @@ -25,8 +29,12 @@ __export PrelGHC -- Concurrency primitives ThreadIdzh + myThreadIdzh forkzh + yieldzh killThreadzh + blockAsyncExceptionszh + unblockAsyncExceptionszh delayzh waitReadzh waitWritezh @@ -37,6 +45,7 @@ __export PrelGHC newMVarzh takeMVarzh putMVarzh + tryTakeMVarzh isEmptyMVarzh -- Parallel @@ -71,9 +80,9 @@ __export PrelGHC zpzh zmzh ztzh - zszh quotIntzh remIntzh + gcdIntzh negateIntzh iShiftLzh iShiftRAzh @@ -144,7 +153,6 @@ __export PrelGHC tanhFloatzh powerFloatzh decodeFloatzh - encodeFloatzh Doublezh zgzhzh @@ -176,14 +184,20 @@ __export PrelGHC tanhDoublezh ztztzhzh decodeDoublezh - encodeDoublezh cmpIntegerzh cmpIntegerIntzh plusIntegerzh minusIntegerzh timesIntegerzh + gcdIntegerzh + quotIntegerzh + remIntegerzh + gcdIntegerzh + gcdIntegerIntzh + divExactIntegerzh quotRemIntegerzh + divModIntegerzh integer2Intzh integer2Wordzh int2Integerzh @@ -232,6 +246,16 @@ __export PrelGHC indexInt64OffAddrzh indexWord64OffAddrzh + readCharOffAddrzh + readIntOffAddrzh + readWordOffAddrzh + readAddrOffAddrzh + readFloatOffAddrzh + readDoubleOffAddrzh + readStablePtrOffAddrzh + readInt64OffAddrzh + readWord64OffAddrzh + writeCharOffAddrzh writeIntOffAddrzh writeWordOffAddrzh @@ -279,6 +303,8 @@ __export PrelGHC unsafeFreezzeArrayzh -- Note zz in the middle unsafeFreezzeByteArrayzh -- Ditto + unsafeThawArrayzh + sizzeofByteArrayzh -- Ditto sizzeofMutableByteArrayzh -- Ditto @@ -297,7 +323,7 @@ __export PrelGHC finalizzeWeakzh ForeignObjzh - makeForeignObjzh + mkForeignObjzh writeForeignObjzh StablePtrzh @@ -315,9 +341,48 @@ __export PrelGHC unsafeCoercezh ; +-- Export PrelErr.error, so that others don't have to import PrelErr +__export PrelErr error ; + +-------------------------------------------------- +-- These imports tell modules low down in the hierarchy that +-- PrelErr and PrelBase are in the same package and +-- should be read from their hi-boot files +import PrelErr @ ; +import PrelNum @ ; + + +-------------------------------------------------- +instance {CCallable Charzh} = zdfCCallableCharzh; +instance {CCallable Doublezh} = zdfCCallableDoublezh; +instance {CCallable Floatzh} = zdfCCallableFloatzh; +instance {CCallable Intzh} = zdfCCallableIntzh; +instance {CCallable Addrzh} = zdfCCallableAddrzh; +instance {CCallable Int64zh} = zdfCCallableInt64zh; +instance {CCallable Word64zh} = zdfCCallableWord64zh; +instance {CCallable Wordzh} = zdfCCallableWordzh; +instance {CCallable ByteArrayzh} = zdfCCallableByteArrayzh; +instance __forall s => {CCallable (MutableByteArrayzh s)} = zdfCCallableMutableByteArrayzh; +instance {CCallable ForeignObjzh} = zdfCCallableForeignObjzh; +instance __forall s => {CCallable (StablePtrzh s)} = zdfCCallableStablePtrzh; -- CCallable and CReturnable have kind (Type AnyBox) so that -- things like Int# can be instances of CCallable. 1 class CCallable a :: ? ; 1 class CReturnable a :: ? ; -1 assert :: __forall [a] => PrelBase.Bool -> a -> a ; +1 assert :: __forall a => PrelBase.Bool -> a -> a ; + +-- These guys don't really exist: +-- +1 zdfCCallableCharzh :: {CCallable Charzh} ; +1 zdfCCallableDoublezh :: {CCallable Doublezh} ; +1 zdfCCallableFloatzh :: {CCallable Floatzh} ; +1 zdfCCallableIntzh :: {CCallable Intzh} ; +1 zdfCCallableAddrzh :: {CCallable Addrzh} ; +1 zdfCCallableInt64zh :: {CCallable Int64zh} ; +1 zdfCCallableWord64zh :: {CCallable Word64zh} ; +1 zdfCCallableWordzh :: {CCallable Wordzh} ; +1 zdfCCallableByteArrayzh :: {CCallable ByteArrayzh} ; +1 zdfCCallableMutableByteArrayzh :: __forall s => {CCallable (MutableByteArrayzh s)} ; +1 zdfCCallableForeignObjzh :: {CCallable ForeignObjzh} ; +1 zdfCCallableStablePtrzh :: __forall a => {CCallable (StablePtrzh a)} ;