summaryrefslogtreecommitdiff
path: root/compiler/coreSyn
diff options
context:
space:
mode:
authorJoachim Breitner <mail@joachim-breitner.de>2015-03-23 10:17:25 +0100
committerJoachim Breitner <mail@joachim-breitner.de>2015-03-23 20:33:35 +0100
commit5673bfc49ec1e54a1540197078041a9da9754fa3 (patch)
tree891071eb3cd5c66d2b0f909448dda5de4e3008da /compiler/coreSyn
parentc1edbdfd9148ad9f74bfe41e76c524f3e775aaaa (diff)
downloadhaskell-5673bfc49ec1e54a1540197078041a9da9754fa3.tar.gz
exprIsBottom should look through type lambdas
as evaluting (\ (@ a) -> e) diverges if and only if evaluating e diverges. This was found in the context of #10180.
Diffstat (limited to 'compiler/coreSyn')
-rw-r--r--compiler/coreSyn/CoreUtils.hs1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/coreSyn/CoreUtils.hs b/compiler/coreSyn/CoreUtils.hs
index 08f4fcdc69..b3855764d8 100644
--- a/compiler/coreSyn/CoreUtils.hs
+++ b/compiler/coreSyn/CoreUtils.hs
@@ -702,6 +702,7 @@ exprIsBottom e
go n (Tick _ e) = go n e
go n (Cast e _) = go n e
go n (Let _ e) = go n e
+ go n (Lam v e) | isTyVar v = go n e
go _ _ = False
{-