-
Notifications
You must be signed in to change notification settings - Fork 2.3k
feat(forge): partial forge migration
#5873
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
forge): partial alloy primitives migrationforge): partial forge migration
| use alloy_primitives::{Address, Bytes, U256}; | ||
| use ethers_addressbook::contract; | ||
| use ethers_core::types::*; | ||
| use ethers_core::types::{BlockId, Chain, NameOrAddress}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wonder what we wanna do with this BlockId type? We also have BlockNumber which is a loosely related struct and I feel we could do some type consolidation. This probably concerns rpc types
mattsse
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm,
clarification on B256
| /// A collection of [HitMap]s | ||
| #[derive(Default, Clone, Debug)] | ||
| pub struct HitMaps(pub HashMap<H256, HitMap>); | ||
| pub struct HitMaps(pub HashMap<B256, HitMap>); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why are we using B256 now?
isn't there an alias for H256?
this can be super confusing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
H stands for Hash which we moved away from months ago :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep, @mattsse i think the alias might be local to reth if you're using that there?
Migrates forge's primitive types to alloy. Types remaining from
ethersaresolc,etherscanandrpcrelated unless highlighted for discussion.