Skip to content
New issue

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

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

Already on GitHub? # to your account

re: Fix clippy::redundant_closure' #5947

Merged
merged 1 commit into from
Dec 22, 2021
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 core/crypto/src/signature.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use rand_core::OsRng;
use secp256k1::Message;
use serde::{Deserialize, Serialize};

pub static SECP256K1: Lazy<secp256k1::Secp256k1> = Lazy::new(|| secp256k1::Secp256k1::new());
pub static SECP256K1: Lazy<secp256k1::Secp256k1> = Lazy::new(secp256k1::Secp256k1::new);

#[derive(Debug, Copy, Clone, Serialize, Deserialize)]
pub enum KeyType {
Expand Down
4 changes: 2 additions & 2 deletions test-utils/runtime-tester/src/scenario_builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ impl ScenarioBuilder {
/// Creates builder with an empty scenario with 4 accounts.
/// Default `use_in_memory_store` -- true.
pub fn new() -> Self {
let network_config = NetworkConfig { seeds: (0..4).map(|x| id_to_seed(x)).collect() };
let network_config = NetworkConfig { seeds: (0..4).map(id_to_seed).collect() };
let runtime_config = RuntimeConfig {
max_total_prepaid_gas: 300 * 10u64.pow(12),
gas_limit: 1_000_000_000_000_000,
Expand All @@ -68,7 +68,7 @@ impl ScenarioBuilder {
/// Changes number of accounts to `num_accounts`.
pub fn number_of_accounts(mut self, num_accounts: usize) -> Self {
self.scenario.network_config =
NetworkConfig { seeds: (0..num_accounts).map(|x| id_to_seed(x)).collect() };
NetworkConfig { seeds: (0..num_accounts).map(id_to_seed).collect() };
self
}

Expand Down