diff --git a/src/key.rs b/src/key.rs index 97ddc21..2ce01ab 100644 --- a/src/key.rs +++ b/src/key.rs @@ -35,7 +35,7 @@ use ffi::{self, CPtr}; /// Basic usage: /// /// ``` -/// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { +/// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1, SecretKey}; /// /// let secp = Secp256k1::new(); @@ -129,7 +129,7 @@ impl SecretKey { /// # Examples /// /// ``` - /// # #[cfg(feature="rand")] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, SecretKey}; /// let secret_key = SecretKey::new(&mut rand::thread_rng()); /// # } @@ -185,7 +185,7 @@ impl SecretKey { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1, SecretKey, KeyPair}; /// /// let secp = Secp256k1::new(); @@ -329,7 +329,7 @@ impl PublicKey { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1, SecretKey, PublicKey}; /// /// let secp = Secp256k1::new(); @@ -377,7 +377,7 @@ impl PublicKey { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1, PublicKey, KeyPair}; /// /// let secp = Secp256k1::new(); @@ -508,7 +508,7 @@ impl PublicKey { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1}; /// /// let secp = Secp256k1::new(); @@ -534,7 +534,7 @@ impl PublicKey { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1, PublicKey}; /// /// let secp = Secp256k1::new(); @@ -650,7 +650,7 @@ impl Ord for PublicKey { /// Basic usage: /// /// ``` -/// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { +/// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, KeyPair, Secp256k1}; /// /// let secp = Secp256k1::new(); @@ -744,7 +744,7 @@ impl KeyPair { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1, SecretKey, KeyPair}; /// /// let secp = Secp256k1::new(); @@ -790,7 +790,7 @@ impl KeyPair { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{Secp256k1, KeyPair}; /// use secp256k1::rand::{RngCore, thread_rng}; /// @@ -914,7 +914,7 @@ impl<'de> ::serde::Deserialize<'de> for KeyPair { /// Basic usage: /// /// ``` -/// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { +/// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{rand, Secp256k1, KeyPair, XOnlyPublicKey}; /// /// let secp = Secp256k1::new(); @@ -1042,7 +1042,7 @@ impl XOnlyPublicKey { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{Secp256k1, KeyPair}; /// use secp256k1::rand::{RngCore, thread_rng}; /// @@ -1107,7 +1107,7 @@ impl XOnlyPublicKey { /// # Examples /// /// ``` - /// # #[cfg(all(feature = "rand", any(feature = "alloc", feature = "std")))] { + /// # #[cfg(all(feature = "rand-std", any(feature = "alloc", feature = "std")))] { /// use secp256k1::{Secp256k1, KeyPair}; /// use secp256k1::rand::{thread_rng, RngCore}; ///