Skip to content

Rename math functions to strict_add/strict_sub (backport #2107) #2109

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 15, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Add ### Changed section to Unreleased CHANGELOG
  • Loading branch information
webmaster128 committed Apr 15, 2024
commit 06f397687548cf704271230cb70066bcc6de56db
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,16 @@ and this project adheres to
`Uint512::add` ([#2092])
- cosmwasm-std: Add `Uint{64,128,256,512}::strict_add` and `::strict_sub` which
are like the `Add`/`Sub` implementations but `const`. ([#2098], [#2107])

[#2092]: https://github.com/CosmWasm/cosmwasm/pull/2092
[#2098]: https://github.com/CosmWasm/cosmwasm/pull/2098
[#2107]: https://github.com/CosmWasm/cosmwasm/pull/2107

### Changed

- cosmwasm-std: Let `Timestamp::plus_nanos`/`::minus_nanos` use
`Uint64::strict_add`/`::strict_sub` and document overflows. ([#2098], [#2107])

[#2092]: https://github.com/CosmWasm/cosmwasm/pull/2092
[#2098]: https://github.com/CosmWasm/cosmwasm/pull/2098
[#2107]: https://github.com/CosmWasm/cosmwasm/pull/2107

Expand Down