7 Maintainer: nbowler@draconx.ca
8 Homepage: http://repo.or.cz/w/altfloat.git
9 Stability: experimental
12 Extra-Source-Files: configure.ac, configure, altfloat.buildinfo.in, cfloat.h
13 Extra-Tmp-Files: altfloat.buildinfo, config.status config.log, config.cache
14 Synopsis: Alternative floating point support for GHC.
16 A replacement for the standard Haskell floating point types and supporting
17 functions. There are a number of shortcomings which I feel severely hinder
18 Haskell's utility for numerical computation. These shortcomings include
20 * There is no way to sanely convert between Haskell's floating types -- not
21 even between Double and CDouble. The implementation of the 'realToFrac'
22 function goes through 'Rational', which loses information as 'Rational'
23 cannot represent all floating point values.
25 * Making floating types an instance of 'Ord' makes no sense. 'Ord' is for
26 totally ordered data types, which floats are not. As a result, a number of
27 library functions (such as 'max' and 'sort') produce nonsensical results.
29 * The 'Enum' instance for floating types similarly makes little sense.
30 While 'fromEnum' and 'toEnum' functions use 'Int' instead of 'Integer',
31 limiting their usefulness, 'pred' and 'succ' can be defined in a much more
34 * Functions that should care about negative zeros, such as 'signum' and
37 * Some functions, such as 'floor', have nonsensical behaviour for
40 * The selection of floating point library functions pales in comparison to
41 C. This problem is made worse since, as noted above, it is impossible to
42 convert losslessly from 'Double' to 'CDouble' in order to use the FFI.
44 * There is no mechanism for handling rounding modes or exceptions.
46 This package is intended to address all of the above issues, and more. All
47 are currently addressed except for rounding modes and exceptions.
49 Also provided, for convenience, is an alternative to the standard Prelude
50 which includes features from this library and the non-overlapping parts of
54 Description: Use the new split integer packages that come with GHC 6.12.
57 Description: Use the integer-gmp package as opposed to integer-simple.
60 Build-Depends: base >= 4 && < 5, ghc-prim
64 Build-Depends: integer-gmp
66 Build-Depends: integer-simple
68 Build-Depends: integer
73 Data.Floating.Classes,
76 Data.Floating.Prelude,
80 Data.Floating.Instances, Data.Poset.Internal, Data.Poset.Instances