Skip to content

Commit 99bc831

Browse files
authored
refactor: add Send and Sync as supertraits of fillers (#65)
1 parent 20cc895 commit 99bc831

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/fill/alloy.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ impl Block for alloy::rpc::types::eth::Header {
272272
}
273273
}
274274

275-
impl<T> Block for alloy::rpc::types::eth::Block<T> {
275+
impl<T: Send + Sync> Block for alloy::rpc::types::eth::Block<T> {
276276
fn fill_block_env(&self, block_env: &mut revm::primitives::BlockEnv) {
277277
self.header.fill_block_env(block_env);
278278
}

src/fill/traits.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use revm::{
44
};
55

66
/// Types that can fill the EVM transaction environment [`TxEnv`].
7-
pub trait Tx {
7+
pub trait Tx: Send + Sync {
88
/// Fill the transaction environment.
99
///
1010
/// ## Note:
@@ -23,7 +23,7 @@ pub trait Tx {
2323
}
2424
}
2525
/// Types that can fill the EVM block environment [`BlockEnv`].
26-
pub trait Block {
26+
pub trait Block: Send + Sync {
2727
/// Fill the block environment.
2828
///
2929
/// ## Note:
@@ -64,7 +64,7 @@ pub trait Block {
6464
/// - `disable_beneficiary_reward` - gated by `optional_beneficiary_reward`
6565
///
6666
/// Cfg fillers should consider these feature gates when implementing the trait.
67-
pub trait Cfg {
67+
pub trait Cfg: Send + Sync {
6868
/// Fill the configuration environment.
6969
fn fill_cfg_env(&self, cfg_env: &mut CfgEnv);
7070

0 commit comments

Comments
 (0)