summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--compiler/basicTypes/Id.hs7
-rw-r--r--compiler/basicTypes/IdInfo.hs7
-rw-r--r--compiler/iface/TcIface.hs2
-rw-r--r--compiler/vectorise/Vectorise.hs2
4 files changed, 4 insertions, 14 deletions
diff --git a/compiler/basicTypes/Id.hs b/compiler/basicTypes/Id.hs
index 387de1ec83..4e8847beee 100644
--- a/compiler/basicTypes/Id.hs
+++ b/compiler/basicTypes/Id.hs
@@ -90,7 +90,6 @@ module Id (
idOccInfo,
-- ** Writing 'IdInfo' fields
- setIdUnfoldingLazily,
setIdUnfolding,
setIdArity,
setIdCallArity,
@@ -139,8 +138,7 @@ import Util
import StaticFlags
-- infixl so you can say (id `set` a `set` b)
-infixl 1 `setIdUnfoldingLazily`,
- `setIdUnfolding`,
+infixl 1 `setIdUnfolding`,
`setIdArity`,
`setIdCallArity`,
`setIdOccInfo`,
@@ -606,9 +604,6 @@ realIdUnfolding :: Id -> Unfolding
-- Expose the unfolding if there is one, including for loop breakers
realIdUnfolding id = unfoldingInfo (idInfo id)
-setIdUnfoldingLazily :: Id -> Unfolding -> Id
-setIdUnfoldingLazily id unfolding = modifyIdInfo (`setUnfoldingInfoLazily` unfolding) id
-
setIdUnfolding :: Id -> Unfolding -> Id
setIdUnfolding id unfolding = modifyIdInfo (`setUnfoldingInfo` unfolding) id
diff --git a/compiler/basicTypes/IdInfo.hs b/compiler/basicTypes/IdInfo.hs
index 0cd2e95c52..4d10f20069 100644
--- a/compiler/basicTypes/IdInfo.hs
+++ b/compiler/basicTypes/IdInfo.hs
@@ -38,7 +38,7 @@ module IdInfo (
demandInfo, setDemandInfo, pprStrictness,
-- ** Unfolding Info
- unfoldingInfo, setUnfoldingInfo, setUnfoldingInfoLazily,
+ unfoldingInfo, setUnfoldingInfo,
-- ** The InlinePragInfo type
InlinePragInfo,
@@ -230,11 +230,6 @@ setOccInfo :: IdInfo -> OccInfo -> IdInfo
setOccInfo info oc = oc `seq` info { occInfo = oc }
-- Try to avoid spack leaks by seq'ing
-setUnfoldingInfoLazily :: IdInfo -> Unfolding -> IdInfo
-setUnfoldingInfoLazily info uf -- Lazy variant to avoid looking at the
- = -- unfolding of an imported Id unless necessary
- info { unfoldingInfo = uf } -- (In this case the demand-zapping is redundant.)
-
setUnfoldingInfo :: IdInfo -> Unfolding -> IdInfo
setUnfoldingInfo info uf
= -- We don't seq the unfolding, as we generate intermediate
diff --git a/compiler/iface/TcIface.hs b/compiler/iface/TcIface.hs
index f8e9505f1c..56c5a5aaf0 100644
--- a/compiler/iface/TcIface.hs
+++ b/compiler/iface/TcIface.hs
@@ -1232,7 +1232,7 @@ tcIdInfo ignore_prags name ty info
= do { unf <- tcUnfolding name ty info if_unf
; let info1 | lb = info `setOccInfo` strongLoopBreaker
| otherwise = info
- ; return (info1 `setUnfoldingInfoLazily` unf) }
+ ; return (info1 `setUnfoldingInfo` unf) }
tcUnfolding :: Name -> Type -> IdInfo -> IfaceUnfolding -> IfL Unfolding
tcUnfolding name _ info (IfCoreUnfold stable if_expr)
diff --git a/compiler/vectorise/Vectorise.hs b/compiler/vectorise/Vectorise.hs
index 77561ffcd8..b78db7c6da 100644
--- a/compiler/vectorise/Vectorise.hs
+++ b/compiler/vectorise/Vectorise.hs
@@ -315,7 +315,7 @@ vectTopBinder var inline expr
(text "Inferred type" <+> ppr vdty)
}
-- Make the vectorised version of binding's name, and set the unfolding used for inlining
- ; var' <- liftM (`setIdUnfoldingLazily` unfolding)
+ ; var' <- liftM (`setIdUnfolding` unfolding)
$ mkVectId var vty
-- Add the mapping between the plain and vectorised name to the state.