packages feed

fixed 0.2 → 0.2.1

raw patch · 3 files changed

+6/−2 lines, 3 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

CHANGELOG.markdown view
@@ -1,3 +1,7 @@+0.2.1+-----+* Fixed bug in `signum`+ 0.2 --- * Convert to/from Double to avoid precision issues.
fixed.cabal view
@@ -1,6 +1,6 @@ name:          fixed category:      Numeric-version:       0.2+version:       0.2.1 license:       BSD3 cabal-version: >= 1.8 license-file:  LICENSE
src/Numeric/Fixed.hs view
@@ -30,7 +30,7 @@   (-) = coerce ((-) :: CInt -> CInt -> CInt)   negate = coerce (negate :: CInt -> CInt)   abs = coerce (abs :: CInt -> CInt)-  signum = coerce (signum :: CInt -> CInt)+  signum (Fixed a) = Fixed $ unsafeShiftL (signum a) 16   Fixed a * Fixed b = Fixed $ fromIntegral (unsafeShiftR (fromIntegral a * fromIntegral b) 16 :: Int64)   fromInteger i = Fixed $ unsafeShiftL (fromInteger i) 16