Clippy cleanup for all targets and nighly rust (also support 1.44.0) (#10445)
* address warnings from 'rustup run beta cargo clippy --workspace' minor refactoring in: - cli/src/cli.rs - cli/src/offline/blockhash_query.rs - logger/src/lib.rs - runtime/src/accounts_db.rs expect some performance improvement AccountsDB::clean_accounts() * address warnings from 'rustup run beta cargo clippy --workspace --tests' * address warnings from 'rustup run nightly cargo clippy --workspace --all-targets' * rustfmt * fix warning stragglers * properly fix clippy warnings test_vote_subscribe() replace ref-to-arc with ref parameters where arc not cloned * Remove lock around JsonRpcRequestProcessor (#10417) automerge * make ancestors parameter optional to avoid forcing construction of empty hash maps Co-authored-by: Greg Fitzgerald <greg@solana.com>
This commit is contained in:
committed by
GitHub
parent
fa3a6c5584
commit
e23340d89e
@@ -721,7 +721,7 @@ mod tests {
|
||||
assert_eq!(poh_recorder.tick_height, 5);
|
||||
assert!(poh_recorder.working_bank.is_none());
|
||||
let mut num_entries = 0;
|
||||
while let Ok(_) = entry_receiver.try_recv() {
|
||||
while entry_receiver.try_recv().is_ok() {
|
||||
num_entries += 1;
|
||||
}
|
||||
assert_eq!(num_entries, 3);
|
||||
@@ -1409,7 +1409,7 @@ mod tests {
|
||||
for _ in 0..(bank.ticks_per_slot() * 2) {
|
||||
poh_recorder.tick();
|
||||
}
|
||||
poh_recorder.set_bank(&bank.clone());
|
||||
poh_recorder.set_bank(&bank);
|
||||
assert_eq!(Some(false), bank.check_hash_age(&genesis_hash, 1));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user