Skip to content

make specialization of Vec::extend and VecDeque::extend_front work for vec::IntoIter with any Allocator, not just Global - #150597

Merged
bors merged 1 commit into
rust-lang:mainfrom
antonilol:extend-from-vec-any-allocator
Jan 4, 2026
Merged

bors merged 1 commit into
rust-lang:mainfrom
antonilol:extend-from-vec-any-allocator

Conversation

@antonilol

@antonilol antonilol commented Jan 2, 2026 •

Copy link
Copy Markdown
Contributor

These functions consume all the elements from the respective collection, but do not care about the Allocator they use. Without specifying one (like in vec::IntoIter<T>) the specialization is only chosen when A=Global.

(extra context: VecDeque::extend_front is unstable and tracked by #146975)

…r vec::IntoIter with any Allocator, not just Global
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Jan 2, 2026
@rustbot

rustbot commented Jan 2, 2026

Copy link
Copy Markdown
Collaborator

r? @jhpratt

rustbot has assigned @jhpratt.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@jhpratt

jhpratt commented Jan 4, 2026

Copy link
Copy Markdown
Member

@bors r+ rollup=iffy

@bors

bors commented Jan 4, 2026

Copy link
Copy Markdown
Collaborator

📌 Commit 9a170fe has been approved by jhpratt

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 4, 2026
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
@bors
bors merged commit 9dd3b23 into rust-lang:main Jan 4, 2026
11 checks passed
@rustbot rustbot added this to the 1.94.0 milestone Jan 4, 2026
rust-timer added a commit that referenced this pull request Jan 4, 2026
Rollup merge of #150597 - antonilol:extend-from-vec-any-allocator, r=jhpratt

make specialization of `Vec::extend` and `VecDeque::extend_front` work for vec::IntoIter with any `Allocator`, not just `Global`

These functions consume all the elements from the respective collection, but do not care about the `Allocator` they use. Without specifying one (like in `vec::IntoIter<T>`) the specialization is only chosen when `A=Global`.

(extra context: `VecDeque::extend_front` is unstable and tracked by #146975)
@antonilol
antonilol deleted the extend-from-vec-any-allocator branch January 4, 2026 20:16
@bors

bors commented Jan 4, 2026

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 9a170fe with merge e29fcf4...

@jhpratt

jhpratt commented Jan 4, 2026

Copy link
Copy Markdown
Member

@bors r-

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jan 4, 2026
@jhpratt

jhpratt commented Jan 4, 2026 •

Copy link
Copy Markdown
Member

bors is currently testing multiple PRs, more than one of which are merged

ref https://rust-lang.zulipchat.com/#narrow/channel/242791-t-infra/topic/bors.20is.20testing.20multiple.20closed.20PRs.20simultaneously/with/566248427

@/bors treeclosed=1000

EDIT: edited to prevent bors from picking up command in a future sync

@jhpratt

jhpratt commented Jan 4, 2026

Copy link
Copy Markdown
Member

@bors retry r- (sync)

@jhpratt

jhpratt commented Jan 4, 2026 •

Copy link
Copy Markdown
Member

@/bors treeclosed-

EDIT: edited to prevent bors from picking up command in a future sync

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-author Status: This is awaiting some action (such as code changes or more information) from the author. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants