summaryrefslogtreecommitdiff
path: root/compiler/utils/BufWrite.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/utils/BufWrite.hs')
-rw-r--r--compiler/utils/BufWrite.hs8
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/utils/BufWrite.hs b/compiler/utils/BufWrite.hs
index 99c043ce41..f4b406fe90 100644
--- a/compiler/utils/BufWrite.hs
+++ b/compiler/utils/BufWrite.hs
@@ -19,7 +19,7 @@ module BufWrite (
bPutStr,
bPutFS,
bPutFZS,
- bPutLitString,
+ bPutPtrString,
bPutReplicate,
bFlush,
) where
@@ -98,15 +98,15 @@ bPutCStringLen b@(BufHandle buf r hdl) cstr@(ptr, len) = do
copyBytes (buf `plusPtr` i) ptr len
writeFastMutInt r (i + len)
-bPutLitString :: BufHandle -> LitString -> IO ()
-bPutLitString b@(BufHandle buf r hdl) l@(LitString a len) = l `seq` do
+bPutPtrString :: BufHandle -> PtrString -> IO ()
+bPutPtrString b@(BufHandle buf r hdl) l@(PtrString a len) = l `seq` do
i <- readFastMutInt r
if (i+len) >= buf_size
then do hPutBuf hdl buf i
writeFastMutInt r 0
if (len >= buf_size)
then hPutBuf hdl a len
- else bPutLitString b l
+ else bPutPtrString b l
else do
copyBytes (buf `plusPtr` i) a len
writeFastMutInt r (i+len)