-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Add String::replace_first
and String::replace_last
#97977
Add String::replace_first
and String::replace_last
#97977
Conversation
Hey! It looks like you've submitted a new PR for the library teams! If this PR contains changes to any Examples of
|
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @kennytm (or someone else) soon. Please see the contribution instructions for more information. |
For now I have manually specified the types in the test and doctest, but these should of course be omitted once the issue is resolved. |
@rustbot label +T-libs-api -T-libs |
This comment has been minimized.
This comment has been minimized.
004561b
to
eb1fa3c
Compare
This comment has been minimized.
This comment has been minimized.
@WilliamVenner FYI: when a PR is ready for review, send a message containing @rustbot author |
@WilliamVenner @rustbot label: +S-inactive |
??? This is blocked by #98941 @JohnCSimon |
@WilliamVenner sorry - my mistake, reopened. |
This comment has been minimized.
This comment has been minimized.
☔ The latest upstream changes (presumably #93455) made this pull request unmergeable. Please resolve the merge conflicts. |
https://github.com/zachs18/rust/tree/string_replace_in_place_rebase |
85d91c6
to
8dd1b5e
Compare
@zachs18 Thank you 🙂 |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
@rustbot label: -S-blocked |
The job Click to see the possible cause of the failure (guessed by this bot)
|
☔ The latest upstream changes (presumably #130674) made this pull request unmergeable. Please resolve the merge conflicts. |
@WilliamVenner |
@WilliamVenner |
Convenience methods that use
match_indices
andreplace_range
to efficiently replace a substring in a string without reallocating, if capacity (and the implementation ofVec::splice
) allows.