Commit f2e74c88 authored by's avatar
Browse files

Improvement to SimplUtils.mkLam

parent 5e3c9a59
......@@ -1027,6 +1027,11 @@ mkLam _env bndrs body
co_vars = tyVarsOfType co
bad bndr = isCoVar bndr && bndr `elemVarSet` co_vars
mkLam' dflags bndrs body@(Lam {})
= mkLam' dflags (bndrs ++ bndrs1) body1
(bndrs1, body1) = collectBinders body
mkLam' dflags bndrs body
| dopt Opt_DoEtaReduction dflags,
Just etad_lam <- tryEtaReduce bndrs body
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment