X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2FcoreSyn%2FCorePrep.lhs;h=6a5a2516dc52f6f155a4f80c34bb7483f2f36ad8;hb=8d6feaef4dce4c9256817be8e7e6da25c21d23d7;hp=ba178b5ea8c00ad23b2be686b93c03c654f619e8;hpb=a819f3db613e6a65cac015a29d6c9d0289938d0f;p=ghc-hetmet.git diff --git a/compiler/coreSyn/CorePrep.lhs b/compiler/coreSyn/CorePrep.lhs index ba178b5..6a5a251 100644 --- a/compiler/coreSyn/CorePrep.lhs +++ b/compiler/coreSyn/CorePrep.lhs @@ -465,7 +465,7 @@ rhsToBody (Cast e co) rhsToBody expr@(Lam {}) | Just no_lam_result <- tryEtaReducePrep bndrs body = return (emptyFloats, no_lam_result) - | all isTyVar bndrs -- Type lambdas are ok + | all isTyCoVar bndrs -- Type lambdas are ok = return (emptyFloats, expr) | otherwise -- Some value lambdas = do { fn <- newVar (exprType expr) @@ -688,7 +688,7 @@ cpe_ExprIsTrivial (App e arg) = isTypeArg arg && cpe_ExprIsTrivial cpe_ExprIsTrivial (Note (SCC _) _) = False cpe_ExprIsTrivial (Note _ e) = cpe_ExprIsTrivial e cpe_ExprIsTrivial (Cast e _) = cpe_ExprIsTrivial e -cpe_ExprIsTrivial (Lam b body) | isTyVar b = cpe_ExprIsTrivial body +cpe_ExprIsTrivial (Lam b body) | isTyCoVar b = cpe_ExprIsTrivial body cpe_ExprIsTrivial _ = False \end{code}