Skip to content

Regression test for type params on eii - #150915

Merged
rust-bors[bot] merged 4 commits into
rust-lang:mainfrom
jdonszelmann:eii-regression-test-149983
Jan 14, 2026
Merged

Regression test for type params on eii#150915
rust-bors[bot] merged 4 commits into
rust-lang:mainfrom
jdonszelmann:eii-regression-test-149983

Conversation

@jdonszelmann

@jdonszelmannjdonszelmann commented Jan 10, 2026

Copy link
Copy Markdown
Contributor

View all comments

Somewhere along the line I fixed this one with my other PRs. This just adds the regression tests

Closes#149983

@rustbotrustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Jan 10, 2026
@rustbot

Copy link
Copy Markdown
Collaborator

r? @petrochenkov

rustbot has assigned @petrochenkov.
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

@rust-log-analyzer

This comment has been minimized.

@Kivooeo

Copy link
Copy Markdown
Member

r? me

r=me when ci is green

@rustbotrustbot assigned Kivooeo and unassigned petrochenkovJan 10, 2026
@jdonszelmann
jdonszelmannforce-pushed the eii-regression-test-149983 branch from 6f628c9 to 6996af3CompareJanuary 11, 2026 15:57
@rustbot

Copy link
Copy Markdown
Collaborator

Some changes occurred in compiler/rustc_attr_parsing

cc @jdonszelmann, @JonathanBrouwer

Some changes occurred in compiler/rustc_hir/src/attrs

cc @jdonszelmann, @JonathanBrouwer

Some changes occurred in compiler/rustc_passes/src/check_attr.rs

cc @jdonszelmann, @JonathanBrouwer

@rustbotrustbot added the A-attributes Area: Attributes (`#[…]`, `#![…]`) label Jan 11, 2026
@rustbot

This comment has been minimized.

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

@Kivooeo ended up rebasing on a little renaming PR so they don't conflict down the line, assigned you too, and improved the error messages a bit so there's no duplicate. Could you take a look again? Despite having already approved the original PR

@Kivooeo

Copy link
Copy Markdown
Member

Could you take a look again?

not sure why this PR contains changes from #150972

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

Cause I rebased on it, to use the new names. This one can merge after that one

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

(i.e. it's a stacked PR, if only github could render that.... :/)

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

I use jj, so I've got autorebase. So I often end up submitting multiple PRs, some stacked on others. Feel free to review after #150972 merged

@rustbot blocked #150972

@rustbotrustbot added S-blocked Status: Blocked on something else such as an RFC or other implementation work. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 11, 2026
@Kivooeo

Copy link
Copy Markdown
Member

check_no_generics is not required anymore?

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

I think not, an EII definition always generates a foreign function, and foreign functions are already disallowed to take generics. This would give a duplicate error which is exactly what I noticed and why I added another commit on top to fix.

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

wait, dya mind if I add another test for that to make sure?

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

okay, I realized you were totally right: we need the other check too make sure the implementation of the EII has no generics. The duplicate error is caused by the fact that an EII with default implementation also contains an implementation, so we error on both the definition and implementation. I'll fix

@Kivooeo

Copy link
Copy Markdown
Member

wait, dya mind if I add another test for that to make sure?

not really, it seems like this check was originally added to fix that issue #149983, so removing it was kinda questionable because maybe it was fixed by some another pr that I'm unaware of and this check already unnecessary

but glad that you found out that this check is still needed ^^

@jdonszelmann

jdonszelmann commented Jan 11, 2026

Copy link
Copy Markdown
ContributorAuthor

wasn't fixed by anything else, but the remove was wrong. Now I just changed it slightly so there's no duplicate error with that last commit, so I think this is the best outcome :)

@Kivooeo

Copy link
Copy Markdown
Member

just to make sure, first two commits will be removed from this pr before merge after #150972 lands right?

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

indeed, same hashes too :)

@Kivooeo

Kivooeo commented Jan 11, 2026

Copy link
Copy Markdown
Member

yeah, i just don't quite sure what "stacked PR" is, so trying to figure out what are we going to do with this next

btw, implementation wise i have no questions, so feel free to r=me once it unblocked after other pr lands

@rust-bors

rust-borsBot commented Jan 12, 2026

Copy link
Copy Markdown
Contributor

☔ The latest upstream changes (presumably #150981) made this pull request unmergeable. Please resolve the merge conflicts.

@jdonszelmann
jdonszelmannforce-pushed the eii-regression-test-149983 branch from b3477f9 to b454f76CompareJanuary 13, 2026 11:03
@rustbot

Copy link
Copy Markdown
Collaborator

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

@jdonszelmann

Copy link
Copy Markdown
ContributorAuthor

@bors r=kivooeo rollup

@rust-borsrust-borsBot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-blocked Status: Blocked on something else such as an RFC or other implementation work. labels Jan 13, 2026
@rust-bors

rust-borsBot commented Jan 13, 2026

Copy link
Copy Markdown
Contributor

📌 Commit b454f76 has been approved by kivooeo

It is now in the queue for this repository.

JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Jan 13, 2026
Regression test for type params on eii
Somewhere along the line I fixed this one with my other PRs. This just adds the regression tests
Closesrust-lang#149983
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Jan 13, 2026
Regression test for type params on eii
Somewhere along the line I fixed this one with my other PRs. This just adds the regression tests
Closesrust-lang#149983
rust-borsBot pushed a commit that referenced this pull request Jan 13, 2026
…uwer
Rollup of 13 pull requests
Successful merges:
- #150586 (rustdoc: Fix intra-doc link bugs involving type aliases and associated items)
- #150677 (Improve std::path::Path::join documentation)
- #150723 (std: move `errno` and related functions into `sys::io`)
- #150737 (diagnostics: make implicit Sized bounds explicit in E0277)
- #150771 (Remove legacy homu `try` and `auto` branch mentions)
- #150915 (Regression test for type params on eii)
- #150962 (Remove `FeedConstTy` and provide ty when lowering const arg)
- #151017 (Port the rustc dump attributes to the attribute parser)
- #151019 (Make `Type::of` support unsized types)
- #151034 (std: Change UEFI env vars to volatile storage)
- #151052 (ui: add regression test for macro resolution ICE (issue #150711))
- #151053 (Reduce flakyness for `tests/rustdoc-gui/notable-trait.goml`)
- #151055 (Emit error instead of delayed bug when meeting mismatch type for const array)
r? @ghost
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Jan 13, 2026
Regression test for type params on eii
Somewhere along the line I fixed this one with my other PRs. This just adds the regression tests
Closesrust-lang#149983
This was referenced Jan 13, 2026
rust-borsBot pushed a commit that referenced this pull request Jan 14, 2026
Rollup of 13 pull requests
Successful merges:
- #150587 (triagebot: add A-rustdoc-js autolabel)
- #150677 (Improve std::path::Path::join documentation)
- #150737 (diagnostics: make implicit Sized bounds explicit in E0277)
- #150771 (Remove legacy homu `try` and `auto` branch mentions)
- #150840 (Make `--print=check-cfg` output compatible `--check-cfg` arguments)
- #150915 (Regression test for type params on eii)
- #151017 (Port the rustc dump attributes to the attribute parser)
- #151019 (Make `Type::of` support unsized types)
- #151031 (Support arrays in type reflection)
- #151043 (armv7-unknown-linux-uclibceabihf.md: Fix bootstrap.toml syntax)
- #151052 (ui: add regression test for macro resolution ICE (issue #150711))
- #151053 (Reduce flakyness for `tests/rustdoc-gui/notable-trait.goml`)
- #151055 (Emit error instead of delayed bug when meeting mismatch type for const array)
r? @ghost
@rust-bors
rust-borsBot merged commit 0d3692a into rust-lang:mainJan 14, 2026
11 checks passed
@rustbotrustbot added this to the 1.94.0 milestone Jan 14, 2026
rust-timer added a commit that referenced this pull request Jan 14, 2026
Rollup merge of #150915 - eii-regression-test-149983, r=kivooeo
Regression test for type params on eii
Somewhere along the line I fixed this one with my other PRs. This just adds the regression tests
Closes#149983
@bjorn3bjorn3 added the F-extern_item_impls `#![feature(extern_item_impls)]` label Jul 8, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-attributesArea: Attributes (`#[…]`, `#![…]`)F-extern_item_impls`#![feature(extern_item_impls)]`S-waiting-on-borsStatus: Waiting on bors to run and complete tests. Bors will change the label on completion.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ICE: eii on generic Instance::mono: DefId(..) has type parameters

6 participants

@jdonszelmann@rustbot@rust-log-analyzer@Kivooeo@petrochenkov@bjorn3