From: Daniela Brozzoni Date: Mon, 22 Jan 2024 21:24:25 +0000 (+0100) Subject: Merge bitcoindevkit/bdk#1253: Remove deprecated checksum routines X-Git-Tag: v1.0.0-alpha.5~11 X-Git-Url: http://internal-gitweb-vhost/script/%22https:/struct.DecoderReader.html?a=commitdiff_plain;h=fbd1d656187859fcb7b84b177e7e9498c15537ea;p=bdk Merge bitcoindevkit/bdk#1253: Remove deprecated checksum routines ed91a4bdb49276057eb7458e1a94653553be24e7 Consolidate `calc_checksum_bytes_internal` routine (Sebastian Falbesoner) 179cfeff51cefda80c16fa4558ba039143a2ad2c Remove deprecated `get_checksum{,_bytes}` routines (Sebastian Falbesoner) Pull request description: ### Description This PR removes the routines `get_checksum` and `get_checksum_bytes` (in the bdk crate, descriptor/checksum.rs), which have been deprecated in 0.24.0. Consequently, the routine `calc_checksum_bytes_internal` is consolidated into `calc_checksum_bytes`, as the boolean parameter `exclude_hash` is not needed anymore. See also the two TODOs in the touched file. ### Notes to the reviewers In the second commit, the signature of the function `calc_checksum_bytes` slightly changes, as the `desc` parameter now is declared as `mut`, in order to change the local variable within the function. My rust experience is rather limited, so I'm not sure if this is a problem for users. IIUC, this is comparable to changing a pass-by-value parameter in C++ from `const std::string desc` to `std::string desc`, which is relevant only for the function implementation, but doesn't change the interface. ### Changelog notice - Remove deprecated `get_checksum` and `get_checksum_bytes` routines ### Checklists #### All Submissions: * [x] I've signed all my commits * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md) * [x] I ran `cargo fmt` and `cargo clippy` before committing ACKs for top commit: danielabrozzoni: ACK ed91a4bdb49276057eb7458e1a94653553be24e7 Tree-SHA512: a29ead57d0369b67e7e79734d7ddc26f42e7ee78b3a6a336cbf9dfa5579f55e7ddbc20b1662d4bedddd7b40a49511dc21c2652911f56d84c9663099b383e1084 --- fbd1d656187859fcb7b84b177e7e9498c15537ea