Skip to main content

FoundryCfg

Trait FoundryCfg 

Source
pub trait FoundryCfg:
    Cfg
    + Clone
    + From<CfgEnv<Self::Spec>>
    + Into<CfgEnv<Self::Spec>>
where Self::Spec: Into<SpecId> + Copy + Debug,
{ // Required methods fn cfg_env(&self) -> &CfgEnv<Self::Spec>; fn cfg_env_mut(&mut self) -> &mut CfgEnv<Self::Spec>; // Provided method fn set_spec_and_gas_params(&mut self, spec: Self::Spec) { ... } }
Expand description

Access to a configuration’s underlying environment and hardfork updates.

Required Methods§

Source

fn cfg_env(&self) -> &CfgEnv<Self::Spec>

Reference to the underlying configuration.

Source

fn cfg_env_mut(&mut self) -> &mut CfgEnv<Self::Spec>

Mutable reference to the underlying configuration.

Provided Methods§

Source

fn set_spec_and_gas_params(&mut self, spec: Self::Spec)

Updates the hardfork and its gas parameters.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl FoundryCfg for MonadCfgEnv

Available on crate feature monad only.
Source§

fn cfg_env(&self) -> &CfgEnv<<MonadCfgEnv as Cfg>::Spec>

Source§

fn cfg_env_mut(&mut self) -> &mut CfgEnv<<MonadCfgEnv as Cfg>::Spec>

Source§

fn set_spec_and_gas_params(&mut self, spec: <MonadCfgEnv as Cfg>::Spec)

Implementors§

Source§

impl<SPEC> FoundryCfg for CfgEnv<SPEC>
where SPEC: Into<SpecId> + Copy + Debug,