Skip to content
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

stake: Pre-allocate lottery ticket index slice. #2710

Merged
merged 1 commit into from Aug 24, 2021

Conversation

rstaudt2
Copy link
Member

This sets the initial capacity of the slice that is created in findTicketIdxs to n to avoid extra allocations since it is a known
fixed size.

This sets the initial capacity of the slice that is created in
`findTicketIdxs` to `n` to avoid extra allocations since it is a known
fixed size.
@davecgh davecgh merged commit d822241 into decred:master Aug 24, 2021
@rstaudt2 rstaudt2 deleted the find-ticket-ids-allocs branch October 28, 2021 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants