From 65b2f18672e2cc4e3cf5706543f73148b90744f5 Mon Sep 17 00:00:00 2001 From: sof Date: Thu, 25 Sep 1997 00:11:46 +0000 Subject: [PATCH] [project @ 1997-09-25 00:11:46 by sof] freeze{Float,Double}Array: state token not threaded properly --- ghc/lib/ghc/ArrBase.lhs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ghc/lib/ghc/ArrBase.lhs b/ghc/lib/ghc/ArrBase.lhs index 0a65a3c..cee229d 100644 --- a/ghc/lib/ghc/ArrBase.lhs +++ b/ghc/lib/ghc/ArrBase.lhs @@ -561,7 +561,7 @@ freezeFloatArray (MutableByteArray ixs arr#) = ST $ \ (S# s#) -> | otherwise = case (readFloatArray# from# cur# s#) of { StateAndFloat# s1# ele -> case (writeFloatArray# to# cur# ele s1#) of { s2# -> - copy (cur# +# 1#) from# to# s1# + copy (cur# +# 1#) from# to# s2# }} freezeDoubleArray (MutableByteArray ixs arr#) = ST $ \ (S# s#) -> @@ -591,7 +591,7 @@ freezeDoubleArray (MutableByteArray ixs arr#) = ST $ \ (S# s#) -> | otherwise = case (readDoubleArray# from# cur# s#) of { StateAndDouble# s1# ele -> case (writeDoubleArray# to# cur# ele s1#) of { s2# -> - copy (cur# +# 1#) end# from# to# s1# + copy (cur# +# 1#) end# from# to# s2# }} unsafeFreezeArray :: Ix ix => MutableArray s ix elt -> ST s (Array ix elt) -- 1.7.10.4