summaryrefslogtreecommitdiff
path: root/ghc/lib/std/Numeric.lhs
diff options
context:
space:
mode:
authorsimonpj <unknown>2001-02-22 13:17:59 +0000
committersimonpj <unknown>2001-02-22 13:17:59 +0000
commitbe2c67eb19565e8d0d9ca5a53f526ce49acf1d92 (patch)
tree5690d06eb3ebce2d7cec39fea9e9881a84a37aa0 /ghc/lib/std/Numeric.lhs
parent72aac89b9ca98591b7f936e80021749b5d8dff76 (diff)
downloadhaskell-be2c67eb19565e8d0d9ca5a53f526ce49acf1d92.tar.gz
[project @ 2001-02-22 13:17:57 by simonpj]
fromInt Remove fromInt from class Num, though it is retained as an overloaded operation (with unchanged type) in PrelNum. There are quite a few consequential changes in the Prelude. I hope I got them all correct! Also fix a bug that meant Integer (and its instances) wasn't getting slurped in by the renamer, even though it was needed for defaulting.
Diffstat (limited to 'ghc/lib/std/Numeric.lhs')
-rw-r--r--ghc/lib/std/Numeric.lhs4
1 files changed, 2 insertions, 2 deletions
diff --git a/ghc/lib/std/Numeric.lhs b/ghc/lib/std/Numeric.lhs
index 7bc88698c8..974c84b01e 100644
--- a/ghc/lib/std/Numeric.lhs
+++ b/ghc/lib/std/Numeric.lhs
@@ -1,5 +1,5 @@
% -----------------------------------------------------------------------------
-% $Id: Numeric.lhs,v 1.10 2000/12/16 17:46:57 qrczak Exp $
+% $Id: Numeric.lhs,v 1.11 2001/02/22 13:17:58 simonpj Exp $
%
% (c) The University of Glasgow, 1997-2000
%
@@ -307,7 +307,7 @@ floatToDigits base x =
(p - 1 + e0) * 3 `div` 10
else
ceiling ((log (fromInteger (f+1)) +
- fromInt e * log (fromInteger b)) /
+ fromIntegral e * log (fromInteger b)) /
log (fromInteger base))
fixup n =
if n >= 0 then