5.7 KiB
5.7 KiB
Release 0.4.1 (2022-06-23)
- Fewer
clonecalls are used when reducing a newRatio<T>. - Conversions to floating point are better at avoiding underflow.
Ratio<T>now implementsDefault, returning a zero value.
Contributors: @cuviper, @lemmih, @MattX
Release 0.4.0 (2021-03-05)
- The optional
num-bigintdependency is now 0.4. - The
Rationalalias forRatio<usize>is now deprecated. It is recommended to use specific type sizes for numeric computation, likeRational32andRational64.
Contributors: @cuviper, @vks
Release 0.3.2 (2020-11-06)
Contributors: @Nemo157
Release 0.3.1 (2020-10-29)
- Handle to_f64() with raw division by zero.
- Better document panic behaviour.
- Clarify the license specification as "MIT OR Apache-2.0".
Contributors: @cuviper, @zetok
Release 0.3.0 (2020-06-13)
Enhancements
Rationow implementsToPrimitive.Rationow implements additional formatting traits:Binary,Octal,LowerHex,UpperHex,LowerExp,UpperExp
- The
Powimplementations have been expanded.Pow<BigInt>andPow<BigUint>are now implemented.Pow<_> for &Ratio<T>now uses&T: Pow.- The inherent
powmethod now uses&T: Pow.
Breaking Changes
num-rationalnow requires Rust 1.31 or greater.- The "i128" opt-in feature was removed, now always available.
- The "num-bigint-std" feature replaces "bigint" with
stdenabled.- The "num-bigint" feature without
stdusesallocon Rust 1.36+.
- The "num-bigint" feature without
Contributors: @cuviper, @MattX, @maxbla
Release 0.2.4 (2020-03-17)
- Fixed
CheckedDivwhen both dividend and divisor are 0. - Fixed
CheckedDivwithmin_value()numerators.
Release 0.2.3 (2020-01-09)
Rationow performs earlier reductions to avoid overflow with+-*/%operators.Ratio::{new_raw, numer, denom}are nowconst fnfor Rust 1.31 and later.- Updated the
autocfgbuild dependency to 1.0.
Contributors: @cuviper, @dingelish, @jimbo1qaz, @maxbla
Release 0.2.2 (2019-06-10)
Contributors: @cuviper, @ignatenkobrain, @vks
Release 0.2.1 (2018-06-22)
- Maintenance release to fix
html_root_url.
Release 0.2.0 (2018-06-19)
Enhancements
Rationow implementsOne::is_oneand theInvtrait.Rationow implementsSumandProduct.Rationow supportsi128andu128components with Rust 1.26+.Rationow implements thePowtrait.
Breaking Changes
num-rationalnow requires rustc 1.15 or greater.- There is now a
stdfeature, enabled by default, along with the implication that building without this feature makes this a#![no_std]crate. A few methods now requireFloatCoreinstead ofFloat. - The
serdedependency has been updated to 1.0, andrustc-serializeis no longer supported bynum-rational. - The optional
num-bigintdependency has been updated to 0.2, and should be enabled using thebigint-stdfeature. In the future, it may be possible to use thebigintfeature withno_std.
Contributors: @clarcharr, @cuviper, @Emerentius, @robomancer-or, @vks
Release 0.1.42 (2018-02-08)
- Maintenance release to update dependencies.
Release 0.1.41 (2018-01-26)
- num-rational now has its own source repository at rust-num/num-rational.
Rationow implementsCheckedAdd,CheckedSub,CheckedMul, andCheckedDiv.Rationow implementsAddAssign,SubAssign,MulAssign,DivAssign, andRemAssignwith eitherRatioor an integer on the right side. The non-assignment operators now also accept integers as an operand.Ratiooperators now make fewerclone()calls.
Thanks to @c410-f3r, @cuviper, and @psimonyi for their contributions!
Prior releases
No prior release notes were kept. Thanks all the same to the many contributors that have made this crate what it is!