-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Implement shrink_to
method on collections
#49400
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
This seems reasonable to me. @rust-lang/libs, does this seem like something that needs an RFC before it goes in? |
I would like some feedback on whether panicking is the best approach here. (In the event that the requested minimum capacity is larger than the current capacity). |
@joshtriplett we're generally much more lax about unstable APIs, so this likely wouldn't require an RFC |
@alexcrichton Ah, OK. Will the examples in the documentation automatically get run as tests? If not, this definitely needs some new tests. |
@joshtriplett they will be run, yeah. |
@bors r+ |
📌 Commit 04f6692 has been approved by |
Implement `shrink_to` method on collections Fixes rust-lang#49385
This is missing a tracking issue. |
Fixes #49385