Merge rust-bitcoin/rust-secp256k1#348: Re-export types to reduce breaking changes downstream

eab549c46c Re-export types to reduce breaking changes downstream (sanket1729)

Pull request description:

  .

ACKs for top commit:
  elichai:
    ACK eab549c46c
  apoelstra:
    ACK eab549c46c

Tree-SHA512: ca3b2c09d68f3401302528779eff4de3204680bd1bbb1795df8e397e562d6e8c10781e083b97c0c3e81c754d70197852e55640976a879b2e8c4584905026736c
This commit is contained in:
Andrew Poelstra 2022-01-03 16:07:54 +00:00
commit f531be3e3c
No known key found for this signature in database
GPG Key ID: C588D63CE41B97C1
1 changed files with 19 additions and 0 deletions

View File

@ -168,6 +168,25 @@ pub use context::global::SECP256K1;
#[cfg(feature = "bitcoin_hashes")]
use hashes::Hash;
// Backwards compatible changes
/// Schnorr Sig related methods
#[deprecated(since = "0.21.0", note = "Use schnorr instead.")]
pub mod schnorrsig {
#[deprecated(since = "0.21.0", note = "Use crate::XOnlyPublicKey instead.")]
/// backwards compatible re-export of xonly key
pub type PublicKey = super::XOnlyPublicKey;
/// backwards compatible re-export of keypair
#[deprecated(since = "0.21.0", note = "Use crate::KeyPair instead.")]
pub type KeyPair = super::KeyPair;
/// backwards compatible re-export of schnorr signatures
#[deprecated(since = "0.21.0", note = "Use schnorr::Signature instead.")]
pub type Signature = super::schnorr::Signature;
}
#[deprecated(since = "0.21.0", note = "Use ecdsa::Signature instead.")]
/// backwards compatible re-export of ecdsa signatures
pub type Signature = ecdsa::Signature;
/// Trait describing something that promises to be a 32-byte random number; in particular,
/// it has negligible probability of being zero or overflowing the group order. Such objects
/// may be converted to `Message`s without any error paths.