mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-01-29 17:18:08 -05:00
chore(clippy): make clippy happy (#2597)
This commit is contained in:
@@ -110,11 +110,7 @@ impl tokio_util::codec::Decoder for StreamCodec {
|
||||
} else if is_whitespace(byte) {
|
||||
whitespaces += 1;
|
||||
}
|
||||
if byte == b'\\' && !is_escaped && in_str {
|
||||
is_escaped = true;
|
||||
} else {
|
||||
is_escaped = false;
|
||||
}
|
||||
is_escaped = byte == b'\\' && !is_escaped && in_str;
|
||||
|
||||
if depth == 0 && idx != start_idx && idx - start_idx + 1 > whitespaces {
|
||||
let bts = buf.split_to(idx + 1);
|
||||
|
||||
@@ -104,7 +104,7 @@ pub fn test_rpc_builder() -> RpcModuleBuilder<
|
||||
RpcModuleBuilder::default()
|
||||
.with_client(NoopProvider::default())
|
||||
.with_pool(testing_pool())
|
||||
.with_network(NoopNetwork::default())
|
||||
.with_network(NoopNetwork)
|
||||
.with_executor(TokioTaskExecutor::default())
|
||||
.with_events(TestCanonStateSubscriptions::default())
|
||||
}
|
||||
|
||||
@@ -373,7 +373,7 @@ mod tests {
|
||||
let eth_api = EthApi::new(
|
||||
NoopProvider::default(),
|
||||
testing_pool(),
|
||||
NoopNetwork::default(),
|
||||
NoopNetwork,
|
||||
EthStateCache::spawn(NoopProvider::default(), Default::default()),
|
||||
);
|
||||
|
||||
@@ -457,7 +457,7 @@ mod tests {
|
||||
let eth_api = EthApi::new(
|
||||
mock_provider,
|
||||
testing_pool(),
|
||||
NoopNetwork::default(),
|
||||
NoopNetwork,
|
||||
EthStateCache::spawn(NoopProvider::default(), Default::default()),
|
||||
);
|
||||
|
||||
|
||||
@@ -765,7 +765,7 @@ mod tests {
|
||||
#[tokio::test]
|
||||
async fn send_raw_transaction() {
|
||||
let noop_provider = NoopProvider::default();
|
||||
let noop_network_provider = NoopNetwork::default();
|
||||
let noop_network_provider = NoopNetwork;
|
||||
|
||||
let pool = testing_pool();
|
||||
|
||||
|
||||
@@ -43,6 +43,6 @@ impl<T: PoolTransaction> TransactionValidator for NoopTransactionValidator<T> {
|
||||
|
||||
impl<T> Default for NoopTransactionValidator<T> {
|
||||
fn default() -> Self {
|
||||
NoopTransactionValidator(PhantomData::default())
|
||||
NoopTransactionValidator(PhantomData)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ impl<'a, K: Key + From<Vec<u8>>, C: TrieCursor<K>> TrieWalker<'a, K, C> {
|
||||
stack: vec![CursorSubNode::default()],
|
||||
can_skip_current_node: false,
|
||||
trie_updates: None,
|
||||
__phantom: PhantomData::default(),
|
||||
__phantom: PhantomData,
|
||||
};
|
||||
|
||||
// Set up the root node of the trie in the stack, if it exists.
|
||||
@@ -59,7 +59,7 @@ impl<'a, K: Key + From<Vec<u8>>, C: TrieCursor<K>> TrieWalker<'a, K, C> {
|
||||
stack,
|
||||
can_skip_current_node: false,
|
||||
trie_updates: None,
|
||||
__phantom: PhantomData::default(),
|
||||
__phantom: PhantomData,
|
||||
};
|
||||
this.update_skip_node();
|
||||
this
|
||||
|
||||
Reference in New Issue
Block a user