diff options
author | Adam Gundry <adam@well-typed.com> | 2015-10-16 13:58:52 +0100 |
---|---|---|
committer | Adam Gundry <adam@well-typed.com> | 2015-10-16 13:58:52 +0100 |
commit | 5a1b4f814f74ec1c48152d97523744518e212777 (patch) | |
tree | 7c2207ecacbd37f12c78dbcf9d4334827164e0fb /compiler/coreSyn/CoreSubst.hs | |
parent | 6757950cdd8bb0af0355539987ee78401a6a8f6b (diff) | |
parent | 808bbdf08058785ae5bc59b5b4f2b04951d4cbbf (diff) | |
download | haskell-wip/orf-reboot.tar.gz |
Merge remote-tracking branch 'origin/master' into wip/orf-rebootwip/orf-reboot
Conflicts:
compiler/rename/RnNames.hs
compiler/typecheck/TcRnMonad.hs
utils/haddock
Diffstat (limited to 'compiler/coreSyn/CoreSubst.hs')
-rw-r--r-- | compiler/coreSyn/CoreSubst.hs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/compiler/coreSyn/CoreSubst.hs b/compiler/coreSyn/CoreSubst.hs index e78ff70888..c1de2051ee 100644 --- a/compiler/coreSyn/CoreSubst.hs +++ b/compiler/coreSyn/CoreSubst.hs @@ -623,12 +623,12 @@ substIdType subst@(Subst _ _ tv_env cv_env) id substIdInfo :: Subst -> Id -> IdInfo -> Maybe IdInfo substIdInfo subst new_id info | nothing_to_do = Nothing - | otherwise = Just (info `setSpecInfo` substSpec subst new_id old_rules + | otherwise = Just (info `setRuleInfo` substSpec subst new_id old_rules `setUnfoldingInfo` substUnfolding subst old_unf) where - old_rules = specInfo info + old_rules = ruleInfo info old_unf = unfoldingInfo info - nothing_to_do = isEmptySpecInfo old_rules && isClosedUnfolding old_unf + nothing_to_do = isEmptyRuleInfo old_rules && isClosedUnfolding old_unf ------------------ @@ -668,12 +668,12 @@ substIdOcc subst v = case lookupIdSubst (text "substIdOcc") subst v of ------------------ -- | Substitutes for the 'Id's within the 'WorkerInfo' given the new function 'Id' -substSpec :: Subst -> Id -> SpecInfo -> SpecInfo -substSpec subst new_id (SpecInfo rules rhs_fvs) - = seqSpecInfo new_spec `seq` new_spec +substSpec :: Subst -> Id -> RuleInfo -> RuleInfo +substSpec subst new_id (RuleInfo rules rhs_fvs) + = seqRuleInfo new_spec `seq` new_spec where subst_ru_fn = const (idName new_id) - new_spec = SpecInfo (map (substRule subst subst_ru_fn) rules) + new_spec = RuleInfo (map (substRule subst subst_ru_fn) rules) (substVarSet subst rhs_fvs) ------------------ |