floatshow 0.2.2 → 0.2.3
raw patch · 3 files changed
+5/−1 lines, 3 filesPVP: major bump suggested
API removals or changes: PVP suggests a major version bump
API changes (from Hackage documentation)
- Text.FShow.Raw: class BinDecode a
+ Text.FShow.Raw: class BinDecode a where decode x = case decodeL x of { (_, n, e) -> (n, e) } decodeL x = case decode x of { (0, _) -> (0, 0, 0) (n, e) -> (integerLog2 (abs n), n, e) } showDigits x = case decodeL x of { (a, _, e) -> fullDecimalDigits a e }
- Text.FShow.Raw: class (Num a, Ord a, BinDecode a) => DecimalFormat a
+ Text.FShow.Raw: class (Num a, Ord a, BinDecode a) => DecimalFormat a where nanTest _ = False infTest _ = False negTest x = x < 0
- Text.FShow.RealFloat: class RealFloat a => DispFloat a
+ Text.FShow.RealFloat: class RealFloat a => DispFloat a where decDigits x = 2 + (8651 * (floatDigits x)) `quot` 28738 binExp x = floatDigits x - 1
- Text.FShow.RealFloat: class FShow a
+ Text.FShow.RealFloat: class FShow a where fshow x = fshowsPrec 0 x "" fshowsPrec _ x s = fshow x ++ s fshowList xs s = showList__ fshows xs s
Files
- Changes +2/−0
- Text/FShow/RealFloat/Internals.hs +2/−0
- floatshow.cabal +1/−1
Changes view
@@ -1,3 +1,5 @@+0.2.3: Adjust to base-4.6, location of quotRemInt changed+0.2.2: Full precision showing types 0.2.1: Typos in haddocks corrected 0.2.0: Raw interface for non-RealFloat types Back to the old integerToDigits because we may now deal with
Text/FShow/RealFloat/Internals.hs view
@@ -19,7 +19,9 @@ #include "MachDeps.h" import GHC.Base+#if __GLASGOW_HASKELL__ < 705 import GHC.Num (quotRemInt)+#endif import GHC.Integer import Data.Array.Base (unsafeAt) import Data.Array.IArray
floatshow.cabal view
@@ -7,7 +7,7 @@ -- The package version. See the Haskell package versioning policy -- (http://www.haskell.org/haskellwiki/Package_versioning_policy) for -- standards guiding when and how versions should be incremented.-Version: 0.2.2+Version: 0.2.3 -- Constraint on the version of Cabal needed to build this package. Cabal-version: >=1.6