Skip to content

Commit eab549c

Browse files
committed
Re-export types to reduce breaking changes downstream
1 parent 6a89320 commit eab549c

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

src/lib.rs

+19
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,25 @@ pub use context::global::SECP256K1;
168168
#[cfg(feature = "bitcoin_hashes")]
169169
use hashes::Hash;
170170

171+
// Backwards compatible changes
172+
/// Schnorr Sig related methods
173+
#[deprecated(since = "0.21.0", note = "Use schnorr instead.")]
174+
pub mod schnorrsig {
175+
#[deprecated(since = "0.21.0", note = "Use crate::XOnlyPublicKey instead.")]
176+
/// backwards compatible re-export of xonly key
177+
pub type PublicKey = super::XOnlyPublicKey;
178+
/// backwards compatible re-export of keypair
179+
#[deprecated(since = "0.21.0", note = "Use crate::KeyPair instead.")]
180+
pub type KeyPair = super::KeyPair;
181+
/// backwards compatible re-export of schnorr signatures
182+
#[deprecated(since = "0.21.0", note = "Use schnorr::Signature instead.")]
183+
pub type Signature = super::schnorr::Signature;
184+
}
185+
186+
#[deprecated(since = "0.21.0", note = "Use ecdsa::Signature instead.")]
187+
/// backwards compatible re-export of ecdsa signatures
188+
pub type Signature = ecdsa::Signature;
189+
171190
/// Trait describing something that promises to be a 32-byte random number; in particular,
172191
/// it has negligible probability of being zero or overflowing the group order. Such objects
173192
/// may be converted to `Message`s without any error paths.

0 commit comments

Comments
 (0)