Skip to content

Fix ICE when reporting host-effect errors for const Fn HRTBs in next trait solver#154804

Open
cijiugechu wants to merge 1 commit intorust-lang:mainfrom
cijiugechu:fix/host-effect-hrtb-ice
Open

Fix ICE when reporting host-effect errors for const Fn HRTBs in next trait solver#154804
cijiugechu wants to merge 1 commit intorust-lang:mainfrom
cijiugechu:fix/host-effect-hrtb-ice

Conversation

@cijiugechu
Copy link
Copy Markdown
Contributor

@cijiugechu cijiugechu commented Apr 4, 2026

Avoid leaking bound vars into the diagnostic selection path for HRTB host-effect predicates.

Closes #151894 .

@rustbot rustbot 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. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) labels Apr 4, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 4, 2026

r? @adwinwhite

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

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: compiler
  • compiler expanded to 69 candidates
  • Random selection from 11 candidates

@cijiugechu cijiugechu changed the title Fix ICE in next trait solver when probing const [const] Fn HRTBs Fix ICE when reporting host-effect errors for const Fn HRTBs in the next trait solver Apr 4, 2026
@cijiugechu cijiugechu changed the title Fix ICE when reporting host-effect errors for const Fn HRTBs in the next trait solver Fix ICE when reporting host-effect errors for const Fn HRTBs in next trait solver Apr 4, 2026
Copy link
Copy Markdown
Member

@ShoyuVanilla ShoyuVanilla left a comment

Choose a reason for hiding this comment

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

Looks good to me, modulo minor nits

View changes since this review

@adwinwhite
Copy link
Copy Markdown
Contributor

Thank you for fixing this.
Could you squash the commits?

@cijiugechu cijiugechu force-pushed the fix/host-effect-hrtb-ice branch from f769a07 to 0b02f67 Compare April 12, 2026 06:47
@cijiugechu
Copy link
Copy Markdown
Contributor Author

Thank you for fixing this. Could you squash the commits?

Squashed

@adwinwhite
Copy link
Copy Markdown
Contributor

@bors r+ rollup

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 12, 2026

📌 Commit 0b02f67 has been approved by adwinwhite

It is now in the queue for this repository.

@rust-bors rust-bors bot 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 Apr 12, 2026
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-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ICE: TraitPredicate has escaping bound vars in select_in_new_trait_solver when reporting error for const [const] Fn HRTB

4 participants