Merge rust-bitcoin/rust-bitcoin#1610: Add KeyPair import to rustdoc example

277e8e96bd Add KeyPair import to rustdoc example (Tobin C. Harding)

Pull request description:

  Recently, and bizarrely, a PR merged that broke `cargo test --doc`.

  Add an import for `KeyPair` to the `schnorr` rustdoc example.

ACKs for top commit:
  apoelstra:
    ACK 277e8e96bd
  Kixunil:
    ACK 277e8e96bd

Tree-SHA512: ad214b668827b35848cc7b260cbd2104a916a82a5a6d242bdc498c62edc9a0e864f4bdb4abcade42924dbaf951223ae80feacbe68d8a4ccb4562d8ead50b23a9
This commit is contained in:
Tobin C. Harding 2023-02-07 08:04:40 +11:00
commit 69688b6487
No known key found for this signature in database
GPG Key ID: 40BF9E4C269D6607
1 changed files with 1 additions and 1 deletions

View File

@ -48,7 +48,7 @@ pub type UntweakedKeyPair = KeyPair;
/// # Examples
/// ```
/// # #[cfg(feature = "rand-std")] {
/// # use bitcoin::schnorr::{TweakedKeyPair, TweakedPublicKey};
/// # use bitcoin::schnorr::{KeyPair, TweakedKeyPair, TweakedPublicKey};
/// # use bitcoin::secp256k1::{rand, Secp256k1};
/// # let secp = Secp256k1::new();
/// # let keypair = TweakedKeyPair::dangerous_assume_tweaked(KeyPair::new(&secp, &mut rand::thread_rng()));