summaryrefslogtreecommitdiff
path: root/compiler/utils/Binary.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/utils/Binary.hs')
-rw-r--r--compiler/utils/Binary.hs17
1 files changed, 0 insertions, 17 deletions
diff --git a/compiler/utils/Binary.hs b/compiler/utils/Binary.hs
index 1c52cb56fb..16d7ccf37d 100644
--- a/compiler/utils/Binary.hs
+++ b/compiler/utils/Binary.hs
@@ -31,10 +31,8 @@ module Binary
-- closeBin,
seekBin,
- seekBy,
tellBin,
castBin,
- isEOFBin,
withBinBuffer,
writeBinMem,
@@ -184,21 +182,6 @@ seekBin h@(BinMem _ ix_r sz_r _) (BinPtr !p) = do
then do expandBin h p; writeFastMutInt ix_r p
else writeFastMutInt ix_r p
-seekBy :: BinHandle -> Int -> IO ()
-seekBy h@(BinMem _ ix_r sz_r _) !off = do
- sz <- readFastMutInt sz_r
- ix <- readFastMutInt ix_r
- let ix' = ix + off
- if (ix' >= sz)
- then do expandBin h ix'; writeFastMutInt ix_r ix'
- else writeFastMutInt ix_r ix'
-
-isEOFBin :: BinHandle -> IO Bool
-isEOFBin (BinMem _ ix_r sz_r _) = do
- ix <- readFastMutInt ix_r
- sz <- readFastMutInt sz_r
- return (ix >= sz)
-
writeBinMem :: BinHandle -> FilePath -> IO ()
writeBinMem (BinMem _ ix_r _ arr_r) fn = do
h <- openBinaryFile fn WriteMode