| 1 |
0.3.7.0 |
| 2 |
|
| 3 |
* Make division (/) on Scientifics slightly more efficient. |
| 4 |
|
| 5 |
* Fix the Show instance to surround negative numbers with parentheses when |
| 6 |
necessary. |
| 7 |
|
| 8 |
* Add (Template Haskell) Lift Scientific instance |
| 9 |
|
| 10 |
* Mark modules as Safe or Trustworthy (Safe Haskell). |
| 11 |
|
| 12 |
0.3.6.2 |
| 13 |
* Due to a regression introduced in 0.3.4.14 the RealFrac methods |
| 14 |
and floatingOrInteger became vulnerable to a space blowup when |
| 15 |
applied to scientifics with huge exponents. This has now been |
| 16 |
fixed again. |
| 17 |
|
| 18 |
0.3.6.1 |
| 19 |
* Fix build on GHC < 8. |
| 20 |
|
| 21 |
0.3.6.0 |
| 22 |
* Make the methods of the Hashable, Eq and Ord instances safe to |
| 23 |
use when applied to scientific numbers coming from untrusted |
| 24 |
sources. Previously these methods first converted their arguments |
| 25 |
to Rational before applying the operation. This is unsafe because |
| 26 |
converting a Scientific to a Rational could fill up all space and |
| 27 |
crash your program when the Scientific has a huge base10Exponent. |
| 28 |
|
| 29 |
Do note that the hash computation of the Hashable Scientific |
| 30 |
instance has been changed because of this improvement! |
| 31 |
|
| 32 |
Thanks to Tom Sydney Kerckhove (@NorfairKing) for pushing me to |
| 33 |
fix this. |
| 34 |
|
| 35 |
* fromRational :: Rational -> Scientific now throws an error |
| 36 |
instead of diverging when applied to a repeating decimal. This |
| 37 |
does mean it will consume space linear in the number of digits of |
| 38 |
the resulting scientific. This makes "fromRational" and the other |
| 39 |
Fractional methods "recip" and "/" a bit safer to use. |
| 40 |
|
| 41 |
* To get the old unsafe but more efficient behaviour the following |
| 42 |
function was added: unsafeFromRational :: Rational -> Scientific. |
| 43 |
|
| 44 |
* Add alternatives for fromRationalRepetend: |
| 45 |
|
| 46 |
fromRationalRepetendLimited |
| 47 |
:: Int -- ^ limit |
| 48 |
-> Rational |
| 49 |
-> Either (Scientific, Rational) |
| 50 |
(Scientific, Maybe Int) |
| 51 |
|
| 52 |
and: |
| 53 |
|
| 54 |
fromRationalRepetendUnlimited |
| 55 |
:: Rational -> (Scientific, Maybe Int) |
| 56 |
|
| 57 |
Thanks to Ian Jeffries (@seagreen) for the idea. |
| 58 |
|
| 59 |
0.3.5.3 |
| 60 |
* Dropped upper version bounds of dependencies |
| 61 |
because it's to much work to maintain. |
| 62 |
|
| 63 |
0.3.5.2 |
| 64 |
* Remove unused ghc-prim dependency. |
| 65 |
* Added unit tests for read and scientificP |
| 66 |
|
| 67 |
0.3.5.1 |
| 68 |
* Replace use of Vector from vector with Array from primitive. |
| 69 |
|
| 70 |
0.3.5.0 |
| 71 |
* Export scientificP :: ReadP Scientific |
| 72 |
(Courtesy of Shlok Datye @shlok) |
| 73 |
|
| 74 |
0.3.4.15 |
| 75 |
* Fix build for base < 4.8. |
| 76 |
|
| 77 |
0.3.4.14 |
| 78 |
* Some minor performance improvements. |
| 79 |
|
| 80 |
0.3.4.13 |
| 81 |
* Support criterion-1.2 |
| 82 |
|
| 83 |
0.3.4.12 |
| 84 |
* Support base-4.10 |
| 85 |
|
| 86 |
0.3.4.11 |
| 87 |
* Support tasty-ant-xml-1.1.0 |
| 88 |
|
| 89 |
0.3.4.10 |
| 90 |
* Tighten lower bound on vector from 0.5 to 0.7 because building with |
| 91 |
vector < 0.7 results in a build error. |
| 92 |
|
| 93 |
* Move the internal modules Math.NumberTheory.Logarithms and |
| 94 |
GHC.Integer.Logarithms.Compat to their own package integer-logarithms so |
| 95 |
other people can share that code. |
| 96 |
|
| 97 |
0.3.4.9 |
| 98 |
* Support QuickCheck-2.9. |
| 99 |
|
| 100 |
0.3.4.8 |
| 101 |
* Make bytestring-builder's installation conditional based on a Cabal flag. |
| 102 |
|
| 103 |
0.3.4.7 |
| 104 |
* Unconditionally export Data.ByteString.Builder.Scientific. |
| 105 |
The bytestring-builder cabal flag has been removed. |
| 106 |
Depend on bytestring-builder for backwards compatibility for GHC < 7.8. |
| 107 |
|
| 108 |
0.3.4.6 |
| 109 |
* Made toDecimalDigits more similar to floatToDigits |
| 110 |
|
| 111 |
Previously: |
| 112 |
|
| 113 |
toDecimalDigits 0 == ([0],1) |
| 114 |
|
| 115 |
Now: |
| 116 |
|
| 117 |
toDecimalDigits 0 == ([0],0) |
| 118 |
|
| 119 |
Because: |
| 120 |
|
| 121 |
Numeric.floatToDigits 10 (0 :: Double) == ([0],0) |
| 122 |
|
| 123 |
|
| 124 |
* Introduce a special case for 0 in fromFloatDigits |
| 125 |
|
| 126 |
fromFloatDigits 0 = 0 |
| 127 |
|
| 128 |
This should fix https://github.com/bos/aeson/issues/369 |
| 129 |
|
| 130 |
0.3.4.5 |
| 131 |
The following are all a courtesy of Oleg Grenrus (phadej): |
| 132 |
|
| 133 |
* Support GHC-8.0.1 |
| 134 |
* Support binary-0.8 |
| 135 |
* Enable Travis continuous integration |
| 136 |
|
| 137 |
0.3.4.4 |
| 138 |
* Improved performance of toDecimalDigits by 13%. |
| 139 |
|
| 140 |
0.3.4.3 |
| 141 |
* Fix build with integer-simple. |
| 142 |
|
| 143 |
0.3.4.2 |
| 144 |
* Fix build on GHC-7.4. |
| 145 |
Courtesy of Adam Bergmark.. |
| 146 |
|
| 147 |
0.3.4.1 |
| 148 |
* Fix build on GHC-7.0.4 |
| 149 |
|
| 150 |
0.3.4.0 |
| 151 |
* Added fromRationalRepetend & toRationalRepetend |
| 152 |
for safely converting from and to rationals |
| 153 |
which have a repeating decimal representation like: |
| 154 |
1 % 28 = 0.03(571428). |
| 155 |
* Added a Binary instance. |
| 156 |
* Various performance improvements. |
| 157 |
* Support vector-0.11 |
| 158 |
* Support tasty-0.11 |
| 159 |
* Support criterion-1.1.0.0 |
| 160 |
|
| 161 |
0.3.3.8 |
| 162 |
* Support QuickCheck-2.8. |
| 163 |
|
| 164 |
0.3.3.7 |
| 165 |
* Fixed both the |
| 166 |
|
| 167 |
Prelude Data.Scientific> reads "0.0" :: [(Data.Scientific.Scientific,String)] |
| 168 |
[(0.0,".0"),(0.0,"")] |
| 169 |
|
| 170 |
problem and the |
| 171 |
|
| 172 |
read " 8" :: Scientific fails, while read " 8" :: Double succeeds |
| 173 |
|
| 174 |
problem. |
| 175 |
|
| 176 |
Courtesy of neongreen. |
| 177 |
|
| 178 |
0.3.3.6 |
| 179 |
* Fixed bug in the x / y method for Scientific. Since I was using |
| 180 |
the default implementation: `x * recip y` the operation would |
| 181 |
diverge when `recip y` had an infinite decimal output. |
| 182 |
This shouldn't happen when the result of / is finite again. |
| 183 |
For example: 0.6 / 0.3 should yield 2.0. |
| 184 |
|
| 185 |
This is now fixed by using the following implementation: |
| 186 |
|
| 187 |
`x / y = fromRational $ toRational x / toRational y` |
| 188 |
|
| 189 |
0.3.3.5 |
| 190 |
* Fixed bug when converting the Scientific: |
| 191 |
`scientific 0 someBigExponent` to a bounded Integral using toBoundedInteger |
| 192 |
or to a bounded RealFloat using toBoundedRealFloat. |
| 193 |
If someBigExponent was big enough to trigger the big-exponent protection |
| 194 |
the beforementioned functions didn't return 0. |
| 195 |
|
| 196 |
This is fixed by explicitly handling a coefficient of 0. |
| 197 |
|
| 198 |
0.3.3.4 |
| 199 |
* Relax upper version bounds of base and deepseq |
| 200 |
for the test suite and benchmarks. |
| 201 |
|
| 202 |
0.3.3.3 |
| 203 |
* Add support for `deepseq-1.4`. |
| 204 |
|
| 205 |
0.3.3.2 |
| 206 |
* Fix parsing of empty digit string (#21). |
| 207 |
|
| 208 |
0.3.3.1 |
| 209 |
* Allow newer tasty, tasty-hunit and criterion. |
| 210 |
|
| 211 |
0.3.3.0 |
| 212 |
* Add the isFloating or isInteger predicates. |
| 213 |
Courtesy of Zejun Wu (@watashi). |
| 214 |
* Add the toRealFloat' and toBoundedInteger functions. |
| 215 |
Courtesy of Fujimura Daisuke (@fujimura). |
| 216 |
|
| 217 |
0.3.2.2 |
| 218 |
* Enable package to link with integer-simple instead of |
| 219 |
integer-gmp using the -finteger-simple cabal flag. |
| 220 |
Courtesy of @k0ral. |
| 221 |
|
| 222 |
0.3.2.1 |
| 223 |
|
| 224 |
* Parameterize inclusion of the Data.ByteString.Builder.Scientific |
| 225 |
module using the bytestring-builder flag. Disabling this flag |
| 226 |
allows building on GHC-7.0.4 which has bytestring-0.9 installed |
| 227 |
by default. |
| 228 |
|
| 229 |
0.3.2.0 |
| 230 |
|
| 231 |
* Add the floatingOrInteger function |
| 232 |
* Fix build on GHC-7.0.4 |
| 233 |
* More efficient and better behaving magnitude computation |
| 234 |
* Lower the number of cached magnitudes to 324 (same as GHC.Float) |
| 235 |
|
| 236 |
0.3.1.0 |
| 237 |
|
| 238 |
* Don't normalize on construction but do it when pretty-printing |
| 239 |
instead. Also provide a manual normalize function. |
| 240 |
* Improve efficiency of toRealFloat |
| 241 |
* Added note about caching magnitudes |
| 242 |
* Dropped dependency on arithmoi |
| 243 |
* Make benchmark easier to build |
| 244 |
* Add junit XML output support (for Jenkins) |
| 245 |
|
| 246 |
0.3.0.2 |
| 247 |
|
| 248 |
* Lower the minimal QuickCheck version. |
| 249 |
* Make sure sized exponents are generated in the QuickCheck tests. |
| 250 |
|
| 251 |
0.3.0.1 |
| 252 |
|
| 253 |
* Fix build for bytestring-0.10.0.* |
| 254 |
|
| 255 |
0.3.0.0 |
| 256 |
|
| 257 |
* Fix a DoS vulnerability that allowed an attacker to crash the |
| 258 |
process by sending a scientific with a huge exponent like |
| 259 |
1e1000000000. |
| 260 |
* Fix various RealFrac methods. |
| 261 |
* Cache some powers of 10 to speed up the magnitude computation. |
| 262 |
* Normalize scientific numbers on construction. |
| 263 |
* Move the Text Builder to its own module & |
| 264 |
provide a ByteString builder |
| 265 |
* Added more documentation |
| 266 |
|
| 267 |
0.2.0.2 |
| 268 |
|
| 269 |
* Widen the dreaded pointlessly tight upper bounds |
| 270 |
|
| 271 |
0.2.0.1 |
| 272 |
|
| 273 |
* Support the latest versions of smallcheck and tasty |
| 274 |
|
| 275 |
0.2.0.0 |
| 276 |
|
| 277 |
* added deriving data |
| 278 |
|
| 279 |
0.1.0.1 |
| 280 |
|
| 281 |
* Loosen upper bounds on package versions |
| 282 |
|
| 283 |
0.1.0.0 |
| 284 |
|
| 285 |
* Fixed bugs & Changed API |
| 286 |
|
| 287 |
0.0.0.2 |
| 288 |
|
| 289 |
* Support building the library on GHC >= 7.0.1 |
| 290 |
|
| 291 |
0.0.0.1 |
| 292 |
|
| 293 |
* Simplification in the Show instance |
| 294 |
* Optimization in fromRealFloat |
| 295 |
|
| 296 |
0.0.0.0 |
| 297 |
|
| 298 |
* Initial commit |