From: simonmar Date: Mon, 29 Jan 2001 17:43:16 +0000 (+0000) Subject: [project @ 2001-01-29 17:43:16 by simonmar] X-Git-Tag: Approximately_9120_patches~2781 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=a6863770dada4d75ec688bd47c2f45328c43b95f;p=ghc-hetmet.git [project @ 2001-01-29 17:43:16 by simonmar] track the changes in absCSyn/PprAbsC.lhs --- diff --git a/ghc/compiler/nativeGen/AbsCStixGen.lhs b/ghc/compiler/nativeGen/AbsCStixGen.lhs index 51a29c6..3e828cf 100644 --- a/ghc/compiler/nativeGen/AbsCStixGen.lhs +++ b/ghc/compiler/nativeGen/AbsCStixGen.lhs @@ -225,15 +225,14 @@ Here we handle top-level things, like @CCodeBlock@s and promote_to_word CharRep = IntRep promote_to_word other = other - -- always at least one padding word: this is the static link field - -- for the garbage collector. - padding_wds = if closureUpdReqd cl_info then - take (max 0 (mIN_UPD_SIZE - length amodes)) zeros - else - [] - - static_link | staticClosureNeedsLink cl_info = [StInt 0] - | otherwise = [] + upd_reqd = closureUpdReqd cl_info + + padding_wds + | upd_reqd = take (max 0 (mIN_UPD_SIZE - length amodes)) zeros + | otherwise = [] + + static_link | upd_reqd || staticClosureNeedsLink cl_info = [StInt 0] + | otherwise = [] zeros = StInt 0 : zeros