Skip to content

Commit b42afae

Browse files
committed
Move trait method
Clean up `MiniscriptKey` implementation for `bitcoin::PublicKey`. - Be uniform, put the trait method implementation below the associated types. - Trait methods have documentation on the trait, remove the unnecessary rustdoc on the implementation.
1 parent 4a174a9 commit b42afae

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/lib.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -191,13 +191,12 @@ impl MiniscriptKey for bitcoin::secp256k1::PublicKey {
191191
}
192192

193193
impl MiniscriptKey for bitcoin::PublicKey {
194-
/// Returns the compressed-ness of the underlying secp256k1 key.
195-
fn is_uncompressed(&self) -> bool { !self.compressed }
196-
197194
type Sha256 = sha256::Hash;
198195
type Hash256 = hash256::Hash;
199196
type Ripemd160 = ripemd160::Hash;
200197
type Hash160 = hash160::Hash;
198+
199+
fn is_uncompressed(&self) -> bool { !self.compressed }
201200
}
202201

203202
impl MiniscriptKey for bitcoin::secp256k1::XOnlyPublicKey {

0 commit comments

Comments
 (0)