Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

First part of multi-mining support #804

Merged
merged 1 commit into from
Mar 24, 2016
Merged

First part of multi-mining support #804

merged 1 commit into from
Mar 24, 2016

Conversation

gavofyork
Copy link
Contributor

Add UsingQueue util class.

@gavofyork gavofyork added the A0-pleasereview 🤓 Pull request needs code review. label Mar 24, 2016
/// Not yet being sealed by a miner, but if one asks for work, we'd prefer they do this.
pending: Option<T>,
/// Currently being sealed by miners.
in_use: Vec<T>,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Functions accepting predicates (below) are always returning only single value. So I guess it's possible to just fetch using some key. LinkedHashMap would be perfect here.
Something like this?
https://contain-rs.github.io/linked-hash-map/linked_hash_map/struct.LinkedHashMap.html

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might be a sensible optimisation to do later, yeah.

@tomusdrw tomusdrw added A6-mustntgrumble 💦 Pull request has areas for improvement. The author need not address them before merging. and removed A0-pleasereview 🤓 Pull request needs code review. labels Mar 24, 2016
@gavofyork gavofyork merged commit 1700b6a into master Mar 24, 2016
@gavofyork gavofyork deleted the usingqueue branch March 24, 2016 16:09
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A6-mustntgrumble 💦 Pull request has areas for improvement. The author need not address them before merging.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants