@@ -144,7 +144,7 @@ impl str::FromStr for SecretKey {
144144/// ```
145145/// [`bincode`]: https://docs.rs/bincode
146146/// [`cbor`]: https://docs.rs/cbor
147- #[ derive( Copy , Clone , Debug , PartialOrd , Ord , PartialEq , Eq , Hash ) ]
147+ #[ derive( Copy , Clone , PartialOrd , Ord , PartialEq , Eq , Hash ) ]
148148#[ repr( transparent) ]
149149pub struct PublicKey ( ffi:: PublicKey ) ;
150150impl_fast_comparisons ! ( PublicKey ) ;
@@ -163,6 +163,10 @@ impl fmt::Display for PublicKey {
163163 fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result { fmt:: LowerHex :: fmt ( self , f) }
164164}
165165
166+ impl fmt:: Debug for PublicKey {
167+ fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result { fmt:: LowerHex :: fmt ( self , f) }
168+ }
169+
166170impl str:: FromStr for PublicKey {
167171 type Err = Error ;
168172 fn from_str ( s : & str ) -> Result < PublicKey , Error > {
@@ -1138,7 +1142,7 @@ impl CPtr for Keypair {
11381142/// ```
11391143/// [`bincode`]: https://docs.rs/bincode
11401144/// [`cbor`]: https://docs.rs/cbor
1141- #[ derive( Copy , Clone , Debug , PartialOrd , Ord , PartialEq , Eq , Hash ) ]
1145+ #[ derive( Copy , Clone , PartialOrd , Ord , PartialEq , Eq , Hash ) ]
11421146pub struct XOnlyPublicKey ( ffi:: XOnlyPublicKey ) ;
11431147impl_fast_comparisons ! ( XOnlyPublicKey ) ;
11441148
@@ -1156,6 +1160,10 @@ impl fmt::Display for XOnlyPublicKey {
11561160 fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result { fmt:: LowerHex :: fmt ( self , f) }
11571161}
11581162
1163+ impl fmt:: Debug for XOnlyPublicKey {
1164+ fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result { fmt:: LowerHex :: fmt ( self , f) }
1165+ }
1166+
11591167impl str:: FromStr for XOnlyPublicKey {
11601168 type Err = Error ;
11611169 fn from_str ( s : & str ) -> Result < XOnlyPublicKey , Error > {
0 commit comments