Skip to content

Commit

Permalink
fix some comments
Browse files Browse the repository at this point in the history
Signed-off-by: geekvest <[email protected]>
  • Loading branch information
geekvest committed Mar 3, 2024
1 parent b93397d commit a6adfd8
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion bitcoin/src/bip32.rs
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ impl serde::Serialize for ChildNumber {
/// Trait that allows possibly failable conversion from a type into a
/// derivation path
pub trait IntoDerivationPath {
/// Convers a given type into a [`DerivationPath`] with possible error
/// Converts a given type into a [`DerivationPath`] with possible error
fn into_derivation_path(self) -> Result<DerivationPath, Error>;
}

Expand Down
2 changes: 1 addition & 1 deletion bitcoin/src/blockdata/block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ impl From<Wtxid> for WitnessMerkleNode {
/// Bitcoin block header.
///
/// Contains all the block's information except the actual transactions, but
/// including a root of a [merkle tree] commiting to all transactions in the block.
/// including a root of a [merkle tree] committing to all transactions in the block.
///
/// [merkle tree]: https://en.wikipedia.org/wiki/Merkle_tree
///
Expand Down
4 changes: 2 additions & 2 deletions bitcoin/src/blockdata/script/borrowed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ use crate::taproot::{LeafVersion, TapLeafHash, TapNodeHash};
/// ## Memory safety
///
/// The type is `#[repr(transparent)]` for internal purposes only!
/// No consumer crate may rely on the represenation of the struct!
/// No consumer crate may rely on the representation of the struct!
///
/// ## References
///
Expand Down Expand Up @@ -441,7 +441,7 @@ impl Script {
/// In Bitcoin Core, there are two ways to count sigops, "accurate" and "legacy".
/// This method uses "accurate" counting. This means that OP_CHECKMULTISIG and its
/// verify variant count for N sigops where N is the number of pubkeys used in the
/// multisig. However, it will count for 20 sigops if CHECKMULTISIG is not preceeded by an
/// multisig. However, it will count for 20 sigops if CHECKMULTISIG is not preceded by an
/// OP_PUSHNUM from 1 - 16 (this would be an invalid script)
///
/// Bitcoin Core uses accurate counting for sigops contained within redeemScripts (P2SH)
Expand Down
2 changes: 1 addition & 1 deletion bitcoin/src/parse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ impl AsRef<core::num::ParseIntError> for ParseIntError {
fn as_ref(&self) -> &core::num::ParseIntError { &self.source }
}

/// Not strictly neccessary but serves as a lint - avoids weird behavior if someone accidentally
/// Not strictly necessary but serves as a lint - avoids weird behavior if someone accidentally
/// passes non-integer to the `parse()` function.
pub(crate) trait Integer:
FromStr<Err = core::num::ParseIntError> + TryFrom<i8> + Sized
Expand Down
2 changes: 1 addition & 1 deletion bitcoin/src/taproot/merkle_branch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ impl TaprootMerkleBranch {
///
/// # Errors
///
/// The function returns an error if the the number of bytes is not an integer multiple of 32 or
/// The function returns an error if the number of bytes is not an integer multiple of 32 or
/// if the number of hashes exceeds 128.
pub fn decode(sl: &[u8]) -> Result<Self, TaprootError> {
if sl.len() % TAPROOT_CONTROL_NODE_SIZE != 0 {
Expand Down

0 comments on commit a6adfd8

Please sign in to comment.