Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

Evaluate and replace Vec::new() with Vec::with_capacity() where capacity is known #55

Open
chipsenkbeil opened this issue Oct 9, 2020 · 0 comments
Milestone

Comments

@chipsenkbeil
Copy link
Owner

For times where we are creating a new Vec via Vec::new(), I believe there are a couple of places where we would know the capacity needed ahead of time. Swapping to Vec::with_capacity() will give a small boost as we can avoid new allocations.

@chipsenkbeil chipsenkbeil added the good first issue Good for newcomers label Oct 9, 2020
@chipsenkbeil chipsenkbeil added this to the 0.1 milestone Oct 21, 2020
@chipsenkbeil chipsenkbeil modified the milestones: 0.1, backlog Oct 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant