forked from rust-bitcoin/rust-bitcoin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Previously we had removed `Default` impl on `siphash24::HashEngine` by reimplementing the type manually. This was a really bad idea as it inevitably led to API differences that broke the build which we didn't notice because of unrelated bug. It should've just split the macro from the start as was suggested but it was claimed to be difficult, I don't think was the case as can be seen by this PR. This commit does what the previous one should've done: it renames the macro to have `_no_default` suffix, creates another one of the original name that calls into `_no_default` one and moves anything related to `Default`. This cleanly ensures all previous hashes stay the same while siphash gets `Default` removed. This also removes all now-conflicting impls from `siphash24` module which makes the module almost identical to what it looked like before the change. The only differences are removed `Default`/`new`, fixes in tests and recent rename of `as_u64` to `to_u64`.
- Loading branch information
Showing
2 changed files
with
36 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters