Skip to content
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

chore: move var to evm args #7492

Merged
merged 1 commit into from
Mar 25, 2024
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
9 changes: 5 additions & 4 deletions crates/anvil/src/cmd.rs
Original file line number Diff line number Diff line change
Expand Up @@ -171,9 +171,6 @@ pub struct NodeArgs {

#[command(flatten)]
pub server_config: ServerConfig,
/// The memory limit per EVM execution in bytes.
#[arg(long)]
pub memory_limit: Option<u64>,
}

#[cfg(windows)]
Expand Down Expand Up @@ -238,7 +235,7 @@ impl NodeArgs {
.with_optimism(self.evm_opts.optimism)
.with_disable_default_create2_deployer(self.evm_opts.disable_default_create2_deployer)
.with_slots_in_an_epoch(self.slots_in_an_epoch)
.with_memory_limit(self.memory_limit)
.with_memory_limit(self.evm_opts.memory_limit)
}

fn account_generator(&self) -> AccountGenerator {
Expand Down Expand Up @@ -507,6 +504,10 @@ pub struct AnvilEvmArgs {
/// Disable the default create2 deployer
#[arg(long, visible_alias = "no-create2")]
pub disable_default_create2_deployer: bool,

/// The memory limit per EVM execution in bytes.
#[arg(long)]
pub memory_limit: Option<u64>,
}

/// Resolves an alias passed as fork-url to the matching url defined in the rpc_endpoints section
Expand Down
2 changes: 1 addition & 1 deletion crates/anvil/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ pub struct NodeConfig {
pub enable_optimism: bool,
/// Slots in an epoch
pub slots_in_an_epoch: u64,
/// Memory configuration layer
/// The memory limit per EVM execution in bytes.
pub memory_limit: Option<u64>,
}

Expand Down
Loading