-
Notifications
You must be signed in to change notification settings - Fork 107
feat: add Hash,[Partial]Eq to test utils #2077
Conversation
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.
Reviewed 2 of 2 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dorimedini-starkware, @giladchase, and @Yael-Starkware)
crates/blockifier/src/test_utils.rs
line 50 at r1 (raw file):
erc20_contract_without_some_syscalls_compiled.json"; #[derive(Clone, Hash, PartialEq, Eq, Copy, Debug)]
Alphabetize?
What does Hash
mean exactly here?
x2
Code quote:
Clone, Hash, PartialEq, Eq, Copy, Debug
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.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dorimedini-starkware, @giladchase, and @Yael-Starkware)
This is useful for aggregator objects that want to keep track (via hashmap) of the number of contracts initialized inside a test. In particular, a soon-to-be-added TransactionGenerator object will use this.
e23b881
to
e3468b9
Compare
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.
Reviewable status: 1 of 2 files reviewed, all discussions resolved (waiting on @dorimedini-starkware, @elintul, and @Yael-Starkware)
crates/blockifier/src/test_utils.rs
line 50 at r1 (raw file):
Previously, elintul (Elin) wrote…
Alphabetize?
What doesHash
mean exactly here?
x2
Done, kept Eq
next to PartialEq
though, they like it that way I think.
Hash
makes it possible for FeatureContract
to be a key in a hashmap.
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.
Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved (waiting on @dorimedini-starkware and @Yael-Starkware)
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.
Reviewed all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved (waiting on @Yael-Starkware)
This is useful for aggregator objects that want to keep track (via hashmap) of the number of contracts initialized inside a test.
In particular, a soon-to-be-added TransactionGenerator object will use this.
This change is