-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
alloc: Move Cow impl to existing ones #150619
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Right now, the `borrow.rs` module starts with a `Cow` impl, although most of them can be found below. This hurts code readability because there is `ToOwned` alongside its impl directly below it. Moving it to the others down below makes sense here, given that the entire enum depends on `ToOwned` anyways.
Collaborator
|
rustbot has assigned @Mark-Simulacrum. Use |
Member
|
@bors r+ rollup |
Collaborator
bors
added a commit
that referenced
this pull request
Jan 4, 2026
Rollup of 5 pull requests Successful merges: - #150554 (test: add regression cases for valtree hashing ICE) - #150597 (make specialization of `Vec::extend` and `VecDeque::extend_front` work for vec::IntoIter with any `Allocator`, not just `Global`) - #150619 (alloc: Move Cow impl to existing ones) - #150660 (THIR pattern building: Pass HIR nodes instead of loose types/spans) - #150671 (miri subtree update) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
that referenced
this pull request
Jan 4, 2026
Rollup merge of #150619 - cvengler:move-cow-impl, r=Mark-Simulacrum alloc: Move Cow impl to existing ones Right now, the `borrow.rs` module starts with a `Cow` impl, although most of them can be found below. This hurts code readability because there is `ToOwned` alongside its impl directly below it. Moving it to the others down below makes sense here, given that the entire enum depends on `ToOwned` anyways.
github-actions bot
pushed a commit
to rust-lang/miri
that referenced
this pull request
Jan 12, 2026
Rollup of 5 pull requests Successful merges: - rust-lang/rust#150554 (test: add regression cases for valtree hashing ICE) - rust-lang/rust#150597 (make specialization of `Vec::extend` and `VecDeque::extend_front` work for vec::IntoIter with any `Allocator`, not just `Global`) - rust-lang/rust#150619 (alloc: Move Cow impl to existing ones) - rust-lang/rust#150660 (THIR pattern building: Pass HIR nodes instead of loose types/spans) - rust-lang/rust#150671 (miri subtree update) r? `@ghost` `@rustbot` modify labels: rollup
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
T-libs
Relevant to the library team, which will review and decide on the PR/issue.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Right now, the
borrow.rsmodule starts with aCowimpl, although most of them can be found below.This hurts code readability because there is
ToOwnedalongside its impl directly below it.Moving it to the others down below makes sense here, given that the entire enum depends on
ToOwnedanyways.