-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Agost Biro <[email protected]>
- Loading branch information
Showing
43 changed files
with
1,861 additions
and
394 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
use revm_primitives::{Address, HashMap, U256}; | ||
|
||
use crate::{serde::ZeroXPrefixedBytes, state::Storage}; | ||
|
||
/// Options for overriding account information. | ||
#[derive(Clone, Debug, PartialEq, serde::Serialize, serde::Deserialize)] | ||
#[serde(rename_all = "camelCase")] | ||
pub struct AccountOverrideOptions { | ||
/// Account balance override. | ||
pub balance: Option<U256>, | ||
#[serde( | ||
default, | ||
skip_serializing_if = "Option::is_none", | ||
with = "crate::serde::optional_u64" | ||
)] | ||
/// Account nonce override. | ||
pub nonce: Option<u64>, | ||
/// Account code override. | ||
pub code: Option<ZeroXPrefixedBytes>, | ||
/// Account storage override. Mutually exclusive with `storage_diff`. | ||
#[serde(rename = "state")] | ||
pub storage: Option<Storage>, | ||
/// Account storage diff override. Mutually exclusive with `storage`. | ||
#[serde(rename = "stateDiff")] | ||
pub storage_diff: Option<Storage>, | ||
} | ||
|
||
/// Type representing a full set of overrides for account information. | ||
pub type StateOverrideOptions = HashMap<Address, AccountOverrideOptions>; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.