@@ -198,7 +198,6 @@ impl SecretKey {
198198 /// ```
199199 #[ inline]
200200 #[ cfg( feature = "rand" ) ]
201- #[ cfg_attr( docsrs, doc( cfg( feature = "rand" ) ) ) ]
202201 pub fn new < R : rand:: Rng + ?Sized > ( rng : & mut R ) -> SecretKey {
203202 let mut data = crate :: random_32_bytes ( rng) ;
204203 unsafe {
@@ -286,7 +285,6 @@ impl SecretKey {
286285 /// # }
287286 /// ```
288287 #[ cfg( feature = "bitcoin_hashes" ) ]
289- #[ cfg_attr( docsrs, doc( cfg( feature = "bitcoin-hashes" ) ) ) ]
290288 #[ inline]
291289 pub fn from_hashed_data < H : ThirtyTwoByteHash + hashes:: Hash > ( data : & [ u8 ] ) -> Self {
292290 <H as hashes:: Hash >:: hash ( data) . into ( )
@@ -355,7 +353,6 @@ impl SecretKey {
355353 /// Constructs an ECDSA signature for `msg` using the global [`SECP256K1`] context.
356354 #[ inline]
357355 #[ cfg( feature = "global-context" ) ]
358- #[ cfg_attr( docsrs, doc( cfg( feature = "global-context" ) ) ) ]
359356 pub fn sign_ecdsa ( & self , msg : Message ) -> ecdsa:: Signature { SECP256K1 . sign_ecdsa ( & msg, self ) }
360357
361358 /// Returns the [`KeyPair`] for this [`SecretKey`].
@@ -393,7 +390,6 @@ impl<T: ThirtyTwoByteHash> From<T> for SecretKey {
393390}
394391
395392#[ cfg( feature = "serde" ) ]
396- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
397393impl serde:: Serialize for SecretKey {
398394 fn serialize < S : serde:: Serializer > ( & self , s : S ) -> Result < S :: Ok , S :: Error > {
399395 if s. is_human_readable ( ) {
@@ -410,7 +406,6 @@ impl serde::Serialize for SecretKey {
410406}
411407
412408#[ cfg( feature = "serde" ) ]
413- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
414409impl < ' de > serde:: Deserialize < ' de > for SecretKey {
415410 fn deserialize < D : serde:: Deserializer < ' de > > ( d : D ) -> Result < Self , D :: Error > {
416411 if d. is_human_readable ( ) {
@@ -469,7 +464,6 @@ impl PublicKey {
469464 /// Creates a new public key from a [`SecretKey`] and the global [`SECP256K1`] context.
470465 #[ inline]
471466 #[ cfg( feature = "global-context" ) ]
472- #[ cfg_attr( docsrs, doc( cfg( feature = "global-context" ) ) ) ]
473467 pub fn from_secret_key_global ( sk : & SecretKey ) -> PublicKey {
474468 PublicKey :: from_secret_key ( SECP256K1 , sk)
475469 }
@@ -740,7 +734,6 @@ impl From<ffi::PublicKey> for PublicKey {
740734}
741735
742736#[ cfg( feature = "serde" ) ]
743- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
744737impl serde:: Serialize for PublicKey {
745738 fn serialize < S : serde:: Serializer > ( & self , s : S ) -> Result < S :: Ok , S :: Error > {
746739 if s. is_human_readable ( ) {
@@ -757,7 +750,6 @@ impl serde::Serialize for PublicKey {
757750}
758751
759752#[ cfg( feature = "serde" ) ]
760- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
761753impl < ' de > serde:: Deserialize < ' de > for PublicKey {
762754 fn deserialize < D : serde:: Deserializer < ' de > > ( d : D ) -> Result < PublicKey , D :: Error > {
763755 if d. is_human_readable ( ) {
@@ -877,7 +869,6 @@ impl KeyPair {
877869 /// [`Error::InvalidSecretKey`] if corresponding public key for the provided secret key is not even.
878870 #[ inline]
879871 #[ cfg( feature = "global-context" ) ]
880- #[ cfg_attr( docsrs, doc( cfg( feature = "global-context" ) ) ) ]
881872 pub fn from_seckey_str_global ( s : & str ) -> Result < KeyPair , Error > {
882873 KeyPair :: from_seckey_str ( SECP256K1 , s)
883874 }
@@ -895,7 +886,6 @@ impl KeyPair {
895886 /// ```
896887 #[ inline]
897888 #[ cfg( feature = "rand" ) ]
898- #[ cfg_attr( docsrs, doc( cfg( feature = "rand" ) ) ) ]
899889 pub fn new < R : rand:: Rng + ?Sized , C : Signing > ( secp : & Secp256k1 < C > , rng : & mut R ) -> KeyPair {
900890 let mut data = crate :: random_32_bytes ( rng) ;
901891 unsafe {
@@ -912,7 +902,6 @@ impl KeyPair {
912902 /// Generates a new random secret key using the global [`SECP256K1`] context.
913903 #[ inline]
914904 #[ cfg( all( feature = "global-context" , feature = "rand" ) ) ]
915- #[ cfg_attr( docsrs, doc( cfg( all( feature = "global-context" , feature = "rand" ) ) ) ) ]
916905 pub fn new_global < R : :: rand:: Rng + ?Sized > ( rng : & mut R ) -> KeyPair {
917906 KeyPair :: new ( SECP256K1 , rng)
918907 }
@@ -989,7 +978,6 @@ impl KeyPair {
989978 /// Constructs an schnorr signature for `msg` using the global [`SECP256K1`] context.
990979 #[ inline]
991980 #[ cfg( all( feature = "global-context" , feature = "rand-std" ) ) ]
992- #[ cfg_attr( docsrs, doc( cfg( all( feature = "global-context" , feature = "rand-std" ) ) ) ) ]
993981 pub fn sign_schnorr ( & self , msg : Message ) -> schnorr:: Signature {
994982 SECP256K1 . sign_schnorr ( & msg, self )
995983 }
@@ -1044,7 +1032,6 @@ impl str::FromStr for KeyPair {
10441032}
10451033
10461034#[ cfg( feature = "serde" ) ]
1047- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
10481035impl serde:: Serialize for KeyPair {
10491036 fn serialize < S : serde:: Serializer > ( & self , s : S ) -> Result < S :: Ok , S :: Error > {
10501037 if s. is_human_readable ( ) {
@@ -1064,7 +1051,6 @@ impl serde::Serialize for KeyPair {
10641051}
10651052
10661053#[ cfg( feature = "serde" ) ]
1067- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
10681054impl < ' de > serde:: Deserialize < ' de > for KeyPair {
10691055 fn deserialize < D : serde:: Deserializer < ' de > > ( d : D ) -> Result < Self , D :: Error > {
10701056 if d. is_human_readable ( ) {
@@ -1439,7 +1425,6 @@ impl fmt::Display for InvalidParityValue {
14391425}
14401426
14411427#[ cfg( feature = "std" ) ]
1442- #[ cfg_attr( docsrs, doc( cfg( feature = "std" ) ) ) ]
14431428impl std:: error:: Error for InvalidParityValue { }
14441429
14451430impl From < InvalidParityValue > for Error {
@@ -1448,7 +1433,6 @@ impl From<InvalidParityValue> for Error {
14481433
14491434/// The parity is serialized as `u8` - `0` for even, `1` for odd.
14501435#[ cfg( feature = "serde" ) ]
1451- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
14521436impl serde:: Serialize for Parity {
14531437 fn serialize < S : serde:: Serializer > ( & self , s : S ) -> Result < S :: Ok , S :: Error > {
14541438 s. serialize_u8 ( self . to_u8 ( ) )
@@ -1457,7 +1441,6 @@ impl serde::Serialize for Parity {
14571441
14581442/// The parity is deserialized as `u8` - `0` for even, `1` for odd.
14591443#[ cfg( feature = "serde" ) ]
1460- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
14611444impl < ' de > serde:: Deserialize < ' de > for Parity {
14621445 fn deserialize < D : serde:: Deserializer < ' de > > ( d : D ) -> Result < Self , D :: Error > {
14631446 struct Visitor ;
@@ -1516,7 +1499,6 @@ impl From<PublicKey> for XOnlyPublicKey {
15161499}
15171500
15181501#[ cfg( feature = "serde" ) ]
1519- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
15201502impl serde:: Serialize for XOnlyPublicKey {
15211503 fn serialize < S : serde:: Serializer > ( & self , s : S ) -> Result < S :: Ok , S :: Error > {
15221504 if s. is_human_readable ( ) {
@@ -1532,7 +1514,6 @@ impl serde::Serialize for XOnlyPublicKey {
15321514}
15331515
15341516#[ cfg( feature = "serde" ) ]
1535- #[ cfg_attr( docsrs, doc( cfg( feature = "serde" ) ) ) ]
15361517impl < ' de > serde:: Deserialize < ' de > for XOnlyPublicKey {
15371518 fn deserialize < D : serde:: Deserializer < ' de > > ( d : D ) -> Result < Self , D :: Error > {
15381519 if d. is_human_readable ( ) {
0 commit comments