Fix typos

This commit is contained in:
shuoer86 2024-01-05 23:10:31 +08:00
parent b63921d625
commit 3568b9b546
No known key found for this signature in database
GPG Key ID: 84A704A15F88ADAD
2 changed files with 3 additions and 3 deletions

View File

@ -213,7 +213,7 @@ impl ScriptBuf {
self.0.extend_from_slice(data.as_bytes());
}
/// Computes the sum of `len` and the lenght of an appropriate push opcode.
/// Computes the sum of `len` and the length of an appropriate push opcode.
pub(in crate::blockdata::script) fn reserved_len_for_slice(len: usize) -> usize {
len + match len {
0..=0x4b => 1,
@ -277,7 +277,7 @@ impl ScriptBuf {
/// Converts this `ScriptBuf` into a [boxed](Box) [`Script`].
///
/// This method reallocates if the capacity is greater than lenght of the script but should not
/// This method reallocates if the capacity is greater than length of the script but should not
/// when they are equal. If you know beforehand that you need to create a script of exact size
/// use [`reserve_exact`](Self::reserve_exact) before adding data to the script so that the
/// reallocation can be avoided.

View File

@ -61,7 +61,7 @@ pub extern crate base64;
/// Encodes and decodes the Bech32 forrmat.
pub extern crate bech32;
/// Rust implementation of cryptographic hash function algorithems.
/// Rust implementation of cryptographic hash function algorithms.
pub extern crate hashes;
/// Re-export the `hex-conservative` crate.