Repository : ssh://darcs.haskell.org//srv/darcs/ghc

On branch  : 

http://hackage.haskell.org/trac/ghc/changeset/6ced9eb4f323248e3d1cdc636afd71cff7775383

>---------------------------------------------------------------

commit 6ced9eb4f323248e3d1cdc636afd71cff7775383
Author: Max Bolingbroke <batterseapo...@hotmail.com>
Date:   Thu Dec 8 14:19:54 2011 +0000

    Avoid overflow when using Deeds maxBound

>---------------------------------------------------------------

 .../supercompile/Supercompile/Evaluator/Deeds.hs   |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/compiler/supercompile/Supercompile/Evaluator/Deeds.hs 
b/compiler/supercompile/Supercompile/Evaluator/Deeds.hs
index 018785e..87768d8 100644
--- a/compiler/supercompile/Supercompile/Evaluator/Deeds.hs
+++ b/compiler/supercompile/Supercompile/Evaluator/Deeds.hs
@@ -23,7 +23,7 @@ instance Monoid Deeds where
     mappend = plusDeeds
 
 instance Bounded Deeds where
-    maxBound = Deeds { sizeLimit = maxBound, stepLimit = maxBound }
+    maxBound = Deeds { sizeLimit = maxBound `div` 2, stepLimit = maxBound 
`div` 2 } -- Try to avoid overflow :-)
     minBound = emptyDeeds
 
 emptyDeeds :: Deeds



_______________________________________________
Cvs-ghc mailing list
Cvs-ghc@haskell.org
http://www.haskell.org/mailman/listinfo/cvs-ghc

Reply via email to