Skip to content

v0.7.0

Choose a tag to compare

@isaacholt100 isaacholt100 released this 28 May 17:02
· 151 commits to master since this release
9f4a08f

Breaking changes

  • Unfortunately version 1.71.0 of the nightly Rust compiler dropped support of the const implementation of common standard library traits. Previous to this version, bnum had const implementations of many standard library traits such as Add, BitOr, PartialEq, etc. which were available using nightly. However, now this is no longer possible with the current version of the nightly Rust compiler (as of 28th May 2023), hence the const implementations of these traits have been dropped for now to allow compatibility with the latest version on nightly. To account for this, many of the methods defined on these traits now have const implementations on the integer types themselves - so for example, there are now BUint::shr and BInt::shr methods which are const.

Other changes

  • The (non-default) arbitrary feature has been introduced, which derives the Arbitrary trait from the arbitrary crate. Note that normally bnum works with no_std, but it cannot with this feature enabled.
  • The following methods are now const on stable: abs_diff, <uint>::{overflowing_neg, wrapping_neg}, wrapping_{shr, shl}, overflowing_{shr, shl}, checked_{shr, shl}, rotate_left, rotate_right, from_be_slice, from_le_slice.

(@lrubasze contributed the addition of the arbitrary support in this release - due to a complication with the CI with his pull request, I'm mentioning him here so he is included in this list of contributors).

What's Changed

Full Changelog: v0.6.0...v0.7.0