mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
fix: typos (#4648)
Co-authored-by: Alexey Shekhirin <a.shekhirin@gmail.com>
This commit is contained in:
@ -153,7 +153,7 @@ RPC:
|
||||
[default: 100]
|
||||
|
||||
--rpc-max-subscriptions-per-connection <RPC_MAX_SUBSCRIPTIONS_PER_CONNECTION>
|
||||
Set the the maximum concurrent subscriptions per connection
|
||||
Set the maximum concurrent subscriptions per connection
|
||||
|
||||
[default: 1024]
|
||||
|
||||
|
||||
@ -169,7 +169,7 @@ impl BlockIndices {
|
||||
|
||||
loop {
|
||||
let Some(old_block_value) = old_hash else {
|
||||
// end of old_hashes canonical chain. New chain has more block then old chain.
|
||||
// end of old_hashes canonical chain. New chain has more blocks than old chain.
|
||||
while let Some(new) = new_hash {
|
||||
// add new blocks to added list.
|
||||
added.push(new.into());
|
||||
@ -204,7 +204,7 @@ impl BlockIndices {
|
||||
old_hash = old_hashes.next();
|
||||
}
|
||||
std::cmp::Ordering::Greater => {
|
||||
// old chain has more past blocks that new chain
|
||||
// old chain has more past blocks than new chain
|
||||
removed.push(old_block_value);
|
||||
old_hash = old_hashes.next()
|
||||
}
|
||||
@ -221,7 +221,7 @@ impl BlockIndices {
|
||||
)
|
||||
}
|
||||
|
||||
/// Remove chain from indices and return dependent chains that needs to be removed.
|
||||
/// Remove chain from indices and return dependent chains that need to be removed.
|
||||
/// Does the cleaning of the tree and removing blocks from the chain.
|
||||
pub fn remove_chain(&mut self, chain: &Chain) -> BTreeSet<BlockChainId> {
|
||||
let mut lose_chains = BTreeSet::new();
|
||||
@ -316,7 +316,7 @@ impl BlockIndices {
|
||||
/// this is function that is going to remove N number of last canonical hashes.
|
||||
///
|
||||
/// NOTE: This is not safe standalone, as it will not disconnect
|
||||
/// blocks that depends on unwinded canonical chain. And should be
|
||||
/// blocks that depend on unwinded canonical chain. And should be
|
||||
/// used when canonical chain is reinserted inside Tree.
|
||||
pub(crate) fn unwind_canonical_chain(&mut self, unwind_to: BlockNumber) {
|
||||
// this will remove all blocks numbers that are going to be replaced.
|
||||
@ -383,7 +383,7 @@ impl BlockIndices {
|
||||
self.canonical_chain.tip()
|
||||
}
|
||||
|
||||
/// Canonical chain needed for execution of EVM. It should contains last 256 block hashes.
|
||||
/// Canonical chain needed for execution of EVM. It should contain last 256 block hashes.
|
||||
#[inline]
|
||||
pub(crate) fn canonical_chain(&self) -> &CanonicalChain {
|
||||
&self.canonical_chain
|
||||
|
||||
@ -47,7 +47,7 @@ impl DerefMut for AppendableChain {
|
||||
}
|
||||
|
||||
impl AppendableChain {
|
||||
/// Crate a new appendable chain from a given chain.
|
||||
/// Create a new appendable chain from a given chain.
|
||||
pub fn new(chain: Chain) -> Self {
|
||||
Self { chain }
|
||||
}
|
||||
|
||||
@ -42,7 +42,7 @@ impl BlockchainTreeConfig {
|
||||
max_unconnected_blocks: usize,
|
||||
) -> Self {
|
||||
if max_reorg_depth > max_blocks_in_chain {
|
||||
panic!("Side chain size should be more then finalization window");
|
||||
panic!("Side chain size should be more than finalization window");
|
||||
}
|
||||
Self {
|
||||
max_blocks_in_chain,
|
||||
|
||||
@ -32,7 +32,7 @@ pub struct ShareableBlockchainTree<DB: Database, C: Consensus, EF: ExecutorFacto
|
||||
}
|
||||
|
||||
impl<DB: Database, C: Consensus, EF: ExecutorFactory> ShareableBlockchainTree<DB, C, EF> {
|
||||
/// Create a new sharable database.
|
||||
/// Create a new shareable database.
|
||||
pub fn new(tree: BlockchainTree<DB, C, EF>) -> Self {
|
||||
Self { tree: Arc::new(RwLock::new(tree)) }
|
||||
}
|
||||
|
||||
@ -108,7 +108,7 @@ impl TxEip4844 {
|
||||
/// Verifies that the given blob data, commitments, and proofs are all valid for this
|
||||
/// transaction.
|
||||
///
|
||||
/// Takes as input the [KzgSettings], which should contain the the parameters derived from the
|
||||
/// Takes as input the [KzgSettings], which should contain the parameters derived from the
|
||||
/// KZG trusted setup.
|
||||
///
|
||||
/// This ensures that the blob transaction payload has the same number of blob data elements,
|
||||
|
||||
@ -5,7 +5,7 @@ use reth_primitives::{hex_literal::hex, H160};
|
||||
/// Dao hardfork beneficiary that received ether from accounts from DAO and DAO creator children.
|
||||
pub static DAO_HARDFORK_BENEFICIARY: H160 = H160(hex!("bf4ed7b27f1d666546e30d74d50d173d20bca754"));
|
||||
|
||||
/// DAO hardfork account that ether was taken and added to beneficiry
|
||||
/// DAO hardfork account that ether was taken and added to beneficiary
|
||||
pub static DAO_HARDKFORK_ACCOUNTS: [H160; 116] = [
|
||||
H160(hex!("d4fe7bc31cedb7bfb8a345f31e668033056b2728")),
|
||||
H160(hex!("b3fb0e5aba0e20e5c49d252dfd30e102b171a425")),
|
||||
|
||||
@ -36,5 +36,5 @@ pub use reth_revm_primitives::*;
|
||||
/// Re-export everything
|
||||
pub use revm;
|
||||
|
||||
/// Etereum DAO hardfork state change data.
|
||||
/// Ethereum DAO hardfork state change data.
|
||||
pub mod eth_dao_fork;
|
||||
|
||||
@ -71,7 +71,7 @@ impl ExecInput {
|
||||
}
|
||||
|
||||
/// Return the next block range determined the number of transactions within it.
|
||||
/// This function walks the the block indices until either the end of the range is reached or
|
||||
/// This function walks the block indices until either the end of the range is reached or
|
||||
/// the number of transactions exceeds the threshold.
|
||||
pub fn next_block_range_with_transaction_threshold<DB: Database>(
|
||||
&self,
|
||||
|
||||
@ -873,7 +873,7 @@ impl<T: PoolTransaction> AddedTransaction<T> {
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns the the replaced transaction if there was one
|
||||
/// Returns the replaced transaction if there was one
|
||||
pub(crate) fn replaced(&self) -> Option<&Arc<ValidPoolTransaction<T>>> {
|
||||
match self {
|
||||
AddedTransaction::Pending(tx) => tx.replaced.as_ref(),
|
||||
|
||||
Reference in New Issue
Block a user