Skip to content

Commit

Permalink
use Cancun config
Browse files Browse the repository at this point in the history
  • Loading branch information
RomarQ committed May 2, 2024
1 parent 920046c commit 5af51ee
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions frame/evm/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ pub mod pallet {

/// EVM config used in the module.
fn config() -> &'static EvmConfig {
&SHANGHAI_CONFIG
&CANCUN_CONFIG
}
}

Expand Down Expand Up @@ -792,7 +792,7 @@ impl<T: Config> GasWeightMapping for FixedGasWeightMapping<T> {
}
}

static SHANGHAI_CONFIG: EvmConfig = EvmConfig::shanghai();
static CANCUN_CONFIG: EvmConfig = EvmConfig::cancun();

impl<T: Config> Pallet<T> {
/// Check whether an account is empty.
Expand Down
2 changes: 1 addition & 1 deletion precompiles/src/testing/handle.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ impl PrecompileHandle for MockHandle {
if self
.record_cost(crate::evm::costs::call_cost(
context.apparent_value,
&evm::Config::london(),
&evm::Config::cancun(),
))
.is_err()
{
Expand Down
4 changes: 2 additions & 2 deletions primitives/evm/src/validation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ mod tests {
UnknownError,
}

static SHANGHAI_CONFIG: evm::Config = evm::Config::shanghai();
static CANCUN_CONFIG: evm::Config = evm::Config::cancun();

impl From<TransactionValidationError> for TestError {
fn from(e: TransactionValidationError) -> Self {
Expand Down Expand Up @@ -345,7 +345,7 @@ mod tests {
} = input;
CheckEvmTransaction::<TestError>::new(
CheckEvmTransactionConfig {
evm_config: &SHANGHAI_CONFIG,
evm_config: &CANCUN_CONFIG,
block_gas_limit: blockchain_gas_limit,
base_fee: blockchain_base_fee,
chain_id: blockchain_chain_id,
Expand Down

0 comments on commit 5af51ee

Please sign in to comment.