Re-export types to reduce breaking changes downstream

This commit is contained in:
sanket1729 2022-01-03 08:53:02 +05:30
parent 6a893208f8
commit eab549c46c
1 changed files with 19 additions and 0 deletions

View File

@ -168,6 +168,25 @@ pub use context::global::SECP256K1;
#[cfg(feature = "bitcoin_hashes")] #[cfg(feature = "bitcoin_hashes")]
use hashes::Hash; 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, /// 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 /// it has negligible probability of being zero or overflowing the group order. Such objects
/// may be converted to `Message`s without any error paths. /// may be converted to `Message`s without any error paths.