summaryrefslogtreecommitdiff
path: root/compiler/simplCore
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2017-03-27 14:33:55 +0100
committerSimon Peyton Jones <simonpj@microsoft.com>2017-03-27 16:31:06 +0100
commitde4723fd6d97b285bb754d8b95531c86d34c4032 (patch)
tree20bc8bb3ead955c04cb21cc6980ae0802c6b5039 /compiler/simplCore
parentfeca929b8f7a7dfe96d06c27d405ce331cdcdb41 (diff)
downloadhaskell-de4723fd6d97b285bb754d8b95531c86d34c4032.tar.gz
Remove utterly bogus code
The commit 6746549772c5cc0ac66c0fce562f297f4d4b80a2 Author: Richard Eisenberg <eir@cis.upenn.edu> Date: Fri Dec 11 18:19:53 2015 -0500 Add kind equalities to GHC. added this entirely bogus code to Simplify.simplLam: env' | Coercion co <- arg = extendCvSubst env bndr co | otherwise = env It's bogus because 'co' is an 'InCoercion', but a CvSubst should have only OutCoercions in it. Moreover, completeBind does the job nicely. This led to an ASSERT failure in an experimental branch; but I have not got a repro case that works on HEAD. But still, the patch deletes code and fixes a bug, so it must be good. The only mystery is why Richard added it in the first place :-). I hope I'm not missing anything. But it validates fine.
Diffstat (limited to 'compiler/simplCore')
-rw-r--r--compiler/simplCore/Simplify.hs7
1 files changed, 1 insertions, 6 deletions
diff --git a/compiler/simplCore/Simplify.hs b/compiler/simplCore/Simplify.hs
index fae040f47a..e78714daab 100644
--- a/compiler/simplCore/Simplify.hs
+++ b/compiler/simplCore/Simplify.hs
@@ -1370,13 +1370,8 @@ simplLam env (bndr:bndrs) body (ApplyToTy { sc_arg_ty = arg_ty, sc_cont = cont }
simplLam env (bndr:bndrs) body (ApplyToVal { sc_arg = arg, sc_env = arg_se
, sc_cont = cont })
= do { tick (BetaReduction bndr)
- ; simplNonRecE env' (zap_unfolding bndr) (arg, arg_se) (bndrs, body) cont }
+ ; simplNonRecE env (zap_unfolding bndr) (arg, arg_se) (bndrs, body) cont }
where
- env' | Coercion co <- arg
- = extendCvSubst env bndr co
- | otherwise
- = env
-
zap_unfolding bndr -- See Note [Zap unfolding when beta-reducing]
| isId bndr, isStableUnfolding (realIdUnfolding bndr)
= setIdUnfolding bndr NoUnfolding