Skip to content

Error on projection of dyn noncompat type in old trait solver#154992

Open
spirali wants to merge 1 commit intorust-lang:mainfrom
spirali:fix-dyn-projection
Open

Error on projection of dyn noncompat type in old trait solver#154992
spirali wants to merge 1 commit intorust-lang:mainfrom
spirali:fix-dyn-projection

Conversation

@spirali
Copy link
Copy Markdown
Contributor

@spirali spirali commented Apr 8, 2026

Trying to fix rust-lang/trait-system-refactor-initiative#269

I am not sure that the check is placed into the right place in the code.

r? lcnr

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Apr 8, 2026
@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Apr 8, 2026
//~^ ERROR the trait `Foo` is not dyn compatible
x.method();
//~^ ERROR the trait `Foo` is not dyn compatible
//~^ ERROR no method named `method` found for reference `&dyn Foo`
Copy link
Copy Markdown
Contributor

@lcnr lcnr Apr 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

View changes since the review

that's annoying :< ideally we'd silence method errors if the self type is not well-formed, tracking that is non-trivial and I don't know how we'd do so myself rn

@lcnr
Copy link
Copy Markdown
Contributor

lcnr commented Apr 9, 2026

lgtm, let's do a crater run, there should be exactly 1 regression from this

@bors try

@rust-bors

This comment has been minimized.

rust-bors bot pushed a commit that referenced this pull request Apr 9, 2026
Error on projection of dyn noncompat type in old trait solver
@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 9, 2026

☀️ Try build successful (CI)
Build commit: a611f2a (a611f2a14e38407ec6717a86a01424ee6fc80762, parent: 1fe72d35998dea48aeecaf7fc07783b0b553f24f)

@lcnr
Copy link
Copy Markdown
Contributor

lcnr commented Apr 9, 2026

@craterbot check

@craterbot
Copy link
Copy Markdown
Collaborator

👌 Experiment pr-154992 created and queued.
🤖 Automatically detected try build a611f2a
🔍 You can check out the queue and this experiment's details.

ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot craterbot added S-waiting-on-crater Status: Waiting on a crater run to be completed. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-crater Status: Waiting on a crater run to be completed. T-compiler Relevant 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.

old solver: check dyn compatability when normalizing

4 participants