summaryrefslogtreecommitdiff
path: root/ghc/lib/glaExts
diff options
context:
space:
mode:
Diffstat (limited to 'ghc/lib/glaExts')
-rw-r--r--ghc/lib/glaExts/LazyST.lhs7
1 files changed, 5 insertions, 2 deletions
diff --git a/ghc/lib/glaExts/LazyST.lhs b/ghc/lib/glaExts/LazyST.lhs
index b8480dfa2a..4c44e30ab4 100644
--- a/ghc/lib/glaExts/LazyST.lhs
+++ b/ghc/lib/glaExts/LazyST.lhs
@@ -100,8 +100,11 @@ unsafeFreezeSTArray (STArray arr) = strictToLazyST (unsafeFreezeArray arr)
strictToLazyST :: STBase.ST s a -> ST s a
strictToLazyST (STBase.ST m) = ST $ \s ->
- let STBase.S# s# = s in
- case m s# of { STBase.STret s2# r -> (r, STBase.S# s2#) }
+ let
+ STBase.S# s# = s
+ STBase.STret s2# r = m s#
+ in
+ (r, STBase.S# s2#)
lazyToStrictST :: ST s a -> STBase.ST s a
lazyToStrictST (ST m) = STBase.ST $ \s ->