projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use full equality for CSE
[ghc-hetmet.git]
/
compiler
/
coreSyn
/
CoreArity.lhs
diff --git
a/compiler/coreSyn/CoreArity.lhs
b/compiler/coreSyn/CoreArity.lhs
index
94297ad
..
be34b07
100644
(file)
--- a/
compiler/coreSyn/CoreArity.lhs
+++ b/
compiler/coreSyn/CoreArity.lhs
@@
-17,7
+17,7
@@
module CoreArity (
import CoreSyn
import CoreFVs
import CoreUtils
import CoreSyn
import CoreFVs
import CoreUtils
-import NewDemand
+import Demand
import TyCon ( isRecursiveTyCon )
import qualified CoreSubst
import CoreSubst ( Subst, substBndr, substBndrs, substExpr
import TyCon ( isRecursiveTyCon )
import qualified CoreSubst
import CoreSubst ( Subst, substBndr, substBndrs, substExpr
@@
-282,7
+282,7
@@
applyStateHack e (AT orig_arity is_bot)
1 + go res (arity-1)
else WARN( arity > 0, ppr arity ) 0
-}
1 + go res (arity-1)
else WARN( arity > 0, ppr arity ) 0
-}
- | otherwise = WARN( arity > 0, ppr arity ) 0
+ | otherwise = WARN( arity > 0, ppr arity <+> ppr ty) 0
\end{code}
Note [State hack and bottoming functions]
\end{code}
Note [State hack and bottoming functions]
@@
-361,7
+361,7
@@
trimArity False (AT _ ATop) = AT 0 ATop -- Bale out
---------------------------
arityType :: Bool -> CoreExpr -> ArityType
arityType _ (Var v)
---------------------------
arityType :: Bool -> CoreExpr -> ArityType
arityType _ (Var v)
- | Just strict_sig <- idNewStrictness_maybe v
+ | Just strict_sig <- idStrictness_maybe v
, (ds, res) <- splitStrictSig strict_sig
, isBotRes res
= AT (length ds) ABot -- Function diverges
, (ds, res) <- splitStrictSig strict_sig
, isBotRes res
= AT (length ds) ABot -- Function diverges
@@
-631,6
+631,6
@@
freshEtaId n subst ty
ty' = substTy subst ty
eta_id' = uniqAway (getTvInScope subst) $
mkSysLocal (fsLit "eta") (mkBuiltinUnique n) ty'
ty' = substTy subst ty
eta_id' = uniqAway (getTvInScope subst) $
mkSysLocal (fsLit "eta") (mkBuiltinUnique n) ty'
- subst' = extendTvInScope subst [eta_id']
+ subst' = extendTvInScope subst eta_id'
\end{code}
\end{code}