Skip to content

Commit

Permalink
feat: add helper from impl (#1407)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattsse authored Oct 1, 2024
1 parent 6608b61 commit 8d99c28
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions crates/eips/src/eip1898.rs
Original file line number Diff line number Diff line change
Expand Up @@ -689,6 +689,12 @@ impl From<B256> for HashOrNumber {
}
}

impl From<&B256> for HashOrNumber {
fn from(value: &B256) -> Self {
Self::Hash(*value)
}
}

impl From<u64> for HashOrNumber {
fn from(value: u64) -> Self {
Self::Number(value)
Expand Down

0 comments on commit 8d99c28

Please sign in to comment.