summaryrefslogtreecommitdiff
path: root/compiler/GHC/StgToCmm
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/GHC/StgToCmm')
-rw-r--r--compiler/GHC/StgToCmm/Closure.hs8
-rw-r--r--compiler/GHC/StgToCmm/Expr.hs8
2 files changed, 8 insertions, 8 deletions
diff --git a/compiler/GHC/StgToCmm/Closure.hs b/compiler/GHC/StgToCmm/Closure.hs
index 3ff745a719..8b9e4f044b 100644
--- a/compiler/GHC/StgToCmm/Closure.hs
+++ b/compiler/GHC/StgToCmm/Closure.hs
@@ -151,23 +151,23 @@ instance (Outputable a) => Outputable (NonVoid a) where
ppr (NonVoid a) = ppr a
nonVoidIds :: [Id] -> [NonVoid Id]
-nonVoidIds ids = [NonVoid id | id <- ids, not (isVoidTy (idType id))]
+nonVoidIds ids = [NonVoid id | id <- ids, not (isZeroBitTy (idType id))]
-- | Used in places where some invariant ensures that all these Ids are
-- non-void; e.g. constructor field binders in case expressions.
-- See Note [Post-unarisation invariants] in "GHC.Stg.Unarise".
assertNonVoidIds :: [Id] -> [NonVoid Id]
-assertNonVoidIds ids = assert (not (any (isVoidTy . idType) ids)) $
+assertNonVoidIds ids = assert (not (any (isZeroBitTy . idType) ids)) $
coerce ids
nonVoidStgArgs :: [StgArg] -> [NonVoid StgArg]
-nonVoidStgArgs args = [NonVoid arg | arg <- args, not (isVoidTy (stgArgType arg))]
+nonVoidStgArgs args = [NonVoid arg | arg <- args, not (isZeroBitTy (stgArgType arg))]
-- | Used in places where some invariant ensures that all these arguments are
-- non-void; e.g. constructor arguments.
-- See Note [Post-unarisation invariants] in "GHC.Stg.Unarise".
assertNonVoidStgArgs :: [StgArg] -> [NonVoid StgArg]
-assertNonVoidStgArgs args = assert (not (any (isVoidTy . stgArgType) args)) $
+assertNonVoidStgArgs args = assert (not (any (isZeroBitTy . stgArgType) args)) $
coerce args
diff --git a/compiler/GHC/StgToCmm/Expr.hs b/compiler/GHC/StgToCmm/Expr.hs
index 6355b55427..77476a4b7d 100644
--- a/compiler/GHC/StgToCmm/Expr.hs
+++ b/compiler/GHC/StgToCmm/Expr.hs
@@ -43,7 +43,7 @@ import GHC.Types.Id
import GHC.Builtin.PrimOps
import GHC.Core.TyCon
import GHC.Core.Type ( isUnliftedType )
-import GHC.Types.RepType ( isVoidTy, countConRepArgs )
+import GHC.Types.RepType ( isZeroBitTy, countConRepArgs )
import GHC.Types.CostCentre ( CostCentreStack, currentCCS )
import GHC.Types.Tickish
import GHC.Data.Maybe
@@ -896,12 +896,12 @@ cgIdApp fun_id args = do
fun = idInfoToAmode fun_info
lf_info = cg_lf fun_info
n_args = length args
- v_args = length $ filter (isVoidTy . stgArgType) args
+ v_args = length $ filter (isZeroBitTy . stgArgType) args
case getCallMethod call_opts fun_name fun_id lf_info n_args v_args (cg_loc fun_info) self_loop_info of
-- A value in WHNF, so we can just return it.
ReturnIt
- | isVoidTy (idType fun_id) -> emitReturn []
- | otherwise -> emitReturn [fun]
+ | isZeroBitTy (idType fun_id) -> emitReturn []
+ | otherwise -> emitReturn [fun]
-- ToDo: does ReturnIt guarantee tagged?
EnterIt -> assert (null args) $ -- Discarding arguments