-
Notifications
You must be signed in to change notification settings - Fork 79
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
Update Set and SetMultimap to use Map2 internally and match new conventions #1524
Conversation
5cadf5d
to
649f0a5
Compare
deal_ops | ||
.0 | ||
.for_each(|key, _| { | ||
let epoch = parse_uint_key(key).unwrap() as i64; | ||
|
||
deal_ops | ||
.for_each(epoch, |ref deal_id| { |
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.
This is a nice change, I had to dig into the code to confirm what this original form was doing. Just to confirm though, what we're doing is: "iterate over the raw keys of the outer hamt, then use those keys to iterate over the inner hamt to look at its values". But in the new form, for_each
gives us the former and for_each_in
gives us the latter.
Thanks for the suggestions, @rvagg. I rewrote some of the comments more fully, and deleted some that are now low value. |
I played around with this a bit and I think we can get rid of the clone: #1525 (although I'm not sure if that'll work in all cases?) |
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.
👍 and with #1525 which seems to pass
Re #1346