From: Ian Lynagh Date: Fri, 24 Apr 2009 16:07:01 +0000 (+0000) Subject: Add more bang patterns, needed to fix the 32bit build X-Git-Tag: 2009-06-25~36 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=2c8eb236a12a4f31a14d971bb84593bf1c32dc5f;p=ghc-base.git Add more bang patterns, needed to fix the 32bit build --- diff --git a/GHC/Int.hs b/GHC/Int.hs index 8b1f4e4..0c70d02 100644 --- a/GHC/Int.hs +++ b/GHC/Int.hs @@ -634,7 +634,7 @@ x# `modInt64#` y# = if r# `neInt64#` intToInt64# 0# then r# `plusInt64#` y# else intToInt64# 0# | otherwise = r# where - r# = x# `remInt64#` y# + !r# = x# `remInt64#` y# instance Read Int64 where readsPrec p s = [(fromInteger x, r) | (x, r) <- readsPrec p s] @@ -656,8 +656,8 @@ instance Bits Int64 where = I64# (word64ToInt64# ((x'# `uncheckedShiftL64#` i'#) `or64#` (x'# `uncheckedShiftRL64#` (64# -# i'#)))) where - x'# = int64ToWord64# x# - i'# = word2Int# (int2Word# i# `and#` int2Word# 63#) + !x'# = int64ToWord64# x# + !i'# = word2Int# (int2Word# i# `and#` int2Word# 63#) bitSize _ = 64 isSigned _ = True diff --git a/GHC/Word.hs b/GHC/Word.hs index a56c2de..c4e3278 100644 --- a/GHC/Word.hs +++ b/GHC/Word.hs @@ -579,7 +579,7 @@ instance Integral Word32 where | i# >=# 0# = smallInteger i# | otherwise = wordToInteger x# where - i# = word2Int# x# + !i# = word2Int# x# #else = smallInteger (word2Int# x#) #endif @@ -730,7 +730,7 @@ instance Bits Word64 where | otherwise = W64# ((x# `uncheckedShiftL64#` i'#) `or64#` (x# `uncheckedShiftRL64#` (64# -# i'#))) where - i'# = word2Int# (int2Word# i# `and#` int2Word# 63#) + !i'# = word2Int# (int2Word# i# `and#` int2Word# 63#) bitSize _ = 64 isSigned _ = False