X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Fprelude%2FPrimOp.lhs;h=836e8c46a36ed54ecd038888df6cb5b1850d1051;hb=39ce3c68d081c7219c5a6ccc8d0a394903f5c336;hp=71ad73378b4d4709db2f264adbcb8ef1d753d369;hpb=8a6fc891c27e3762b3cb47cf16f9c79d029710dc;p=ghc-hetmet.git diff --git a/ghc/compiler/prelude/PrimOp.lhs b/ghc/compiler/prelude/PrimOp.lhs index 71ad733..836e8c4 100644 --- a/ghc/compiler/prelude/PrimOp.lhs +++ b/ghc/compiler/prelude/PrimOp.lhs @@ -1213,13 +1213,17 @@ primOpInfo (IndexOffForeignObjOp kind) primOpInfo (WriteOffAddrOp kind) = let - s = alphaTy; s_tv = alphaTyVar + s = betaTy; s_tv = betaTyVar (str, prim_ty, _) = getPrimRepInfo kind op_str = _PK_ ("write" ++ str ++ "OffAddr#") + + tvs + | kind == StablePtrRep = [s_tv,alphaTyVar] + | otherwise = [s_tv] in -- NB: *Prim*Result -- - PrimResult op_str [s_tv] + PrimResult op_str tvs [addrPrimTy, intPrimTy, prim_ty, mkStatePrimTy s] statePrimTyCon VoidRep [s]