From 1f4e6afca6e99a64c53bedb69e00a50212db281a Mon Sep 17 00:00:00 2001 From: simonm Date: Fri, 19 Feb 1999 10:48:58 +0000 Subject: [PATCH 1/1] [project @ 1999-02-19 10:48:58 by simonm] Fix negate (toInteger (minBound :: Int)). --- ghc/lib/std/PrelNum.lhs | 1 + 1 file changed, 1 insertion(+) diff --git a/ghc/lib/std/PrelNum.lhs b/ghc/lib/std/PrelNum.lhs index b092c9b..96dc994 100644 --- a/ghc/lib/std/PrelNum.lhs +++ b/ghc/lib/std/PrelNum.lhs @@ -242,6 +242,7 @@ instance Num Integer where (*) (J# s1 d1) (J# s2 d2) = case timesInteger# s1 d1 s2 d2 of (# s, d #) -> J# s d + negate i@(S# (-2147483648#)) = 2147483648 negate (S# i) = S# (negateInt# i) negate (J# s d) = J# (negateInt# s) d -- 1.7.10.4