[project @ 2000-01-19 16:47:16 by sewardj]
authorsewardj <unknown>
Wed, 19 Jan 2000 16:47:16 +0000 (16:47 +0000)
committersewardj <unknown>
Wed, 19 Jan 2000 16:47:16 +0000 (16:47 +0000)
amodeToStix: correctly compute offset for CHARLIKE_closure-s.

ghc/compiler/nativeGen/StixPrim.lhs

index 11b6cd6..c9323ec 100644 (file)
@@ -352,7 +352,7 @@ amodeToStix (CCharLike (CLit (MachChar c)))
 amodeToStix (CCharLike x)
   = StIndex PtrRep charLike off
   where
-    off = StPrim IntMulOp [amodeToStix x, StInt (toInteger (fixedHdrSize+1))]
+    off = StPrim IntMulOp [amodeToStix x, StInt (toInteger charLikeSize)]
 
 amodeToStix (CIntLike (CLit (MachInt i _)))
   = StLitLbl ((<>) (ptext SLIT("INTLIKE_closure+")) (int off))