8000 Fix typos by rex4539 · Pull Request #224 · rust-bitcoin/rust-bitcoin · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fix typos #224

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 23, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/blockdata/script.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ fn build_scriptint(n: i64) -> Vec<u8> {
/// This is a bit crazy and subtle, but it makes sense: you can load
/// 32-bit numbers and do anything with them, which back when mult/div
/// was allowed, could result in up to a 64-bit number. We don't want
/// overflow since that's suprising --- and we don't want numbers that
/// overflow since that's surprising --- and we don't want numbers that
/// don't fit in 64 bits (for efficiency on modern processors) so we
/// simply say, anything in excess of 32 bits is no longer a number.
/// This is basically a ranged type implementation.
Expand Down
2 changes: 1 addition & 1 deletion src/blockdata/transaction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ impl Default for TxOut {
/// However, in protocols where transactions may legitimately have 0 inputs, e.g.
/// when parties are cooperatively funding a transaction, the "00 means Segwit"
/// heuristic does not work. Since Segwit requires such a transaction be encoded
/// in the the original transaction format (since it has no inputs and therefore
/// in the original transaction format (since it has no inputs and therefore
/// no input witnesses), a traditionally encoded transaction may have the `0001`
/// Segwit flag in it, which confuses most Segwit parsers including the one in
/// Bitcoin Core.
Expand Down
2 changes: 1 addition & 1 deletion src/consensus/params.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ pub struct Params {
pub rule_change_activation_threshold: u32,
/// Number of blocks with the same set of rules.
pub miner_confirmation_window: u32,
/// Proof of work limit value. It cointans the lowest possible difficulty.
/// Proof of work limit value. It contains the lowest possible difficulty.
pub pow_limit: Uint256,
/// Expected amount of time to mine one block.
pub pow_target_spacing: u64,
Expand Down
2 changes: 1 addition & 1 deletion src/internal_macros.rs
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ macro_rules! impl_array_newtype {
// manually implement comparison to get little-endian ordering
// (we need this for our numeric types; non-numeric ones shouldn't
// be ordered anyway except to put them in BTrees or whatever, and
// they don't care how we order as long as we're consisistent).
// they don't care how we order as long as we're consistent).
for i in 0..$len {
if self[$len - 1 - i] < other[$len - 1 - i] { return ::std::cmp::Ordering::Less; }
if self[$len - 1 - i] > other[$len - 1 - i] { return ::std::cmp::Ordering::Greater; }
Expand Down
2 changes: 1 addition & 1 deletion src/network/message.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ pub struct RawNetworkMessage {
pub enum SocketResponse {
/// A message was received
MessageReceived(NetworkMessage),
/// An error occured and the socket needs to close
/// An error occurred and the socket needs to close
ConnectionFailed(util::Error, Sender<()& 8000 gt;)
}

Expand Down
2 changes: 1 addition & 1 deletion src/network/message_network.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ pub struct VersionMessage {
pub nonce: u64,
/// A string describing the peer's software
pub user_agent: String,
/// The height of the maxmimum-work blockchain that the peer is aware of
/// The height of the maximum-work blockchain that the peer is aware of
pub start_height: i32,
/// Whether the receiving peer should relay messages to the sender; used
/// if the sender is bandwidth-limited and would like to support bloom
Expand Down
2 changes: 1 addition & 1 deletion src/util/address.rs
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ impl Address {
}

/// Create a witness pay to public key address from a public key
/// This is the native segwit address type for an output redemable with a single signature
/// This is the native segwit address type for an output redeemable with a single signature
pub fn p2wpkh (pk: &PublicKey, network: Network) -> Address {
Address {
network: network,
Expand Down
2 changes: 1 addition & 1 deletion src/util/bip32.rs
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ impl serde::Serialize for ChildNumber {
pub enum Error {
/// A pk->pk derivation was attempted on a hardened key
CannotDeriveFromHardenedKey,
/// A secp256k1 error occured
/// A secp256k1 error occurred
Ecdsa(secp256k1::Error),
/// A child number was provided that was out of range
InvalidChildNumber(ChildNumber),
Expand Down
4 changes: 2 additions & 2 deletions src/util/contracthash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
//

//! Pay-to-contract-hash supporte
//! Pay-to-contract-hash support
//!
//! See Appendix A of the Blockstream sidechains whitepaper
//! at http://blockstream.com/sidechains.pdf for details of
Expand All @@ -32,7 +32,7 @@ use util::{address, hash};
#[cfg(feature="fuzztarget")] use fuzz_u 9E81 til::sha2;
#[cfg(not(feature="fuzztarget"))] use crypto::sha2;

/// Encoding of "pubkey here" in script; from bitcoin core `src/script/script.h`
/// Encoding of "pubkey here" in script; from Bitcoin Core `src/script/script.h`
static PUBKEY: u8 = 0xFE;

/// A contract-hash error
Expand Down
2 changes: 1 addition & 1 deletion src/util/misc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ pub fn hex_bytes(data: &str) -> Result<Vec<u8>, encode::Error> {
};

// Convert bytes representing characters to their represented value and combine lsn and msn.
// The and_then and map are crucial for performance, in comparision to using ? and then
// The and_then and map are crucial for performance, in comparison to using ? and then
// using the results of that for the calculation it's nearly twice as fast. Using bit
// shifting and or instead of multiply and add on the other hand doesn't show a significant
// increase in performance.
Expand Down
2 changes: 1 addition & 1 deletion src/util/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ pub trait BitArray {
/// Create all-zeros value
fn zero() -> Self;

/// Create value represeting one
/// Create value representing one
fn one() -> Self;
}

Expand Down
0