[commit: ghc] wip/nested-cpr: Check mAX_CPR_SIZE in dmdAnalVarApp (1e68e8f)
git at git.haskell.org
git at git.haskell.org
Wed Jan 15 18:07:09 UTC 2014
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/nested-cpr
Link : http://ghc.haskell.org/trac/ghc/changeset/1e68e8fe95577d5db452e86144c5af0918b8c3b8/ghc
>---------------------------------------------------------------
commit 1e68e8fe95577d5db452e86144c5af0918b8c3b8
Author: Joachim Breitner <mail at joachim-breitner.de>
Date: Thu Dec 5 18:01:34 2013 +0000
Check mAX_CPR_SIZE in dmdAnalVarApp
>---------------------------------------------------------------
1e68e8fe95577d5db452e86144c5af0918b8c3b8
compiler/stranal/DmdAnal.lhs | 2 ++
1 file changed, 2 insertions(+)
diff --git a/compiler/stranal/DmdAnal.lhs b/compiler/stranal/DmdAnal.lhs
index 42153b3..5409538 100644
--- a/compiler/stranal/DmdAnal.lhs
+++ b/compiler/stranal/DmdAnal.lhs
@@ -532,6 +532,8 @@ dmdAnalVarApp env dmd fun args
| Just con <- isDataConWorkId_maybe fun -- Data constructor
, isVanillaDataCon con
, n_val_args == dataConRepArity con -- Saturated
+ , dataConRepArity con > 0
+ , dataConRepArity con < 10
, let cpr_info
| isProductTyCon (dataConTyCon con) = cprProdRes arg_rets
| otherwise = cprSumRes (dataConTag con)
More information about the ghc-commits
mailing list