Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
i-m-aditya committed Jun 24, 2024
1 parent 656b6f0 commit 53b31fa
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions crates/optimism/evm/src/execute.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ where
{
fn op_executor<DB>(&self, db: DB) -> OpBlockExecutor<EvmConfig, DB>
where
DB: Database<Error = ProviderError>,
DB: Database<Error: Into<ProviderError> + std::fmt::Display>,
{
OpBlockExecutor::new(
self.chain_spec.clone(),
Expand All @@ -69,19 +69,21 @@ impl<EvmConfig> BlockExecutorProvider for OpExecutorProvider<EvmConfig>
where
EvmConfig: ConfigureEvm,
{
type Executor<DB: Database<Error = ProviderError>> = OpBlockExecutor<EvmConfig, DB>;
type Executor<DB: Database<Error: Into<ProviderError> + std::fmt::Display>> =
OpBlockExecutor<EvmConfig, DB>;

type BatchExecutor<DB: Database<Error = ProviderError>> = OpBatchExecutor<EvmConfig, DB>;
type BatchExecutor<DB: Database<Error: Into<ProviderError> + std::fmt::Display>> =
OpBatchExecutor<EvmConfig, DB>;
fn executor<DB>(&self, db: DB) -> Self::Executor<DB>
where
DB: Database<Error = ProviderError>,
DB: Database<Error: Into<ProviderError> + std::fmt::Display>,
{
self.op_executor(db)
}

fn batch_executor<DB>(&self, db: DB, prune_modes: PruneModes) -> Self::BatchExecutor<DB>
where
DB: Database<Error = ProviderError>,
DB: Database<Error: Into<ProviderError> + std::fmt::Display>,
{
let executor = self.op_executor(db);
OpBatchExecutor {
Expand Down Expand Up @@ -118,7 +120,7 @@ where
mut evm: Evm<'_, Ext, &mut State<DB>>,
) -> Result<(Vec<Receipt>, u64), BlockExecutionError>
where
DB: Database<Error = ProviderError>,
DB: Database<Error: Into<ProviderError> + std::fmt::Display>,
{
// apply pre execution changes
apply_beacon_root_contract_call(
Expand Down Expand Up @@ -255,7 +257,7 @@ impl<EvmConfig, DB> OpBlockExecutor<EvmConfig, DB> {
impl<EvmConfig, DB> OpBlockExecutor<EvmConfig, DB>
where
EvmConfig: ConfigureEvm,
DB: Database<Error = ProviderError>,
DB: Database<Error: Into<ProviderError> + std::fmt::Display>,
{
/// Configures a new evm configuration and block environment for the given block.
///
Expand Down Expand Up @@ -337,7 +339,7 @@ where
impl<EvmConfig, DB> Executor<DB> for OpBlockExecutor<EvmConfig, DB>
where
EvmConfig: ConfigureEvm,
DB: Database<Error = ProviderError>,
DB: Database<Error: Into<ProviderError> + std::fmt::Display>,
{
type Input<'a> = BlockExecutionInput<'a, BlockWithSenders>;
type Output = BlockExecutionOutput<Receipt>;
Expand Down Expand Up @@ -394,7 +396,7 @@ impl<EvmConfig, DB> OpBatchExecutor<EvmConfig, DB> {
impl<EvmConfig, DB> BatchExecutor<DB> for OpBatchExecutor<EvmConfig, DB>
where
EvmConfig: ConfigureEvm,
DB: Database<Error = ProviderError>,
DB: Database<Error: Into<ProviderError> + std::fmt::Display>,
{
type Input<'a> = BlockExecutionInput<'a, BlockWithSenders>;
type Output = ExecutionOutcome;
Expand Down

0 comments on commit 53b31fa

Please sign in to comment.