-
Notifications
You must be signed in to change notification settings - Fork 269
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
Clean up the hashes dependency/feature #628
Conversation
8f94237
to
446e045
Compare
@@ -21,8 +21,7 @@ default = ["std"] | |||
std = ["alloc", "secp256k1-sys/std"] | |||
# allow use of Secp256k1::new and related API that requires an allocator | |||
alloc = ["secp256k1-sys/alloc"] | |||
bitcoin-hashes = ["bitcoin_hashes"] # Feature alias because of the underscore. | |||
bitcoin-hashes-std = ["std", "bitcoin_hashes", "bitcoin_hashes/std"] | |||
hashes-std = ["std", "hashes/std"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whenever we hit MSRV 1.60 we can replace all the -std
ones with:
std = ["hashes?/std"]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Already tracked here: rust-bitcoin/rust-bitcoin#1722 but thanks for mentioning, I didn't actually know what "weak dependencies" meant - TIL.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK, only went over the diff 446e045
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK 446e045.
299952b
to
c5279be
Compare
c5279be
to
fca3cd3
Compare
dd78b87
to
a522bf2
Compare
a522bf2
to
834d9ea
Compare
I botched the rebase, will fix tomorrow. |
6cec5e7
to
c965c94
Compare
Use the more terse `hashes` by way of the `package` field in the manifest. Allows us to remove the ugly feature alias "bitcoin-hashes" -> "bitcoin_hashes" and removes all the bother with the underscore. Why did we not think of this 2 years ago?
Now that we have `hashes` as the crate name of `bitcoin_hashes` we can slightly clean up the import statements. This is based on the convention we have to import things directly from the crate if we depend on it and not from the crate level re-export.
c965c94
to
6fdd3b1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK 6fdd3b1
Use the more terse
hashes
by way of thepackage
field in the manifest.Allows us to remove the ugly feature alias "bitcoin-hashes" -> "bitcoin_hashes" and removes all the bother with the underscore.