Skip to content

Conversation

@Wilfred
Copy link
Contributor

@Wilfred Wilfred commented Dec 29, 2025

Previously both valid and invalid Rust code could crash r-a due to a cyclic query during lowering.

Closes #21006

AI disclosure: I haven't worked on the lowerer before, so I created the first draft of this code with Claude. However, I've reviewed all the code myself (to the best of my ability), wrote the comments myself, verified that the added test fails without these changes, and I will apply my human brain to any feedback on the PR. I hope that's OK.

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 29, 2025
@rustbot

This comment has been minimized.

@Wilfred Wilfred force-pushed the fix_cycle_projections branch from 823abe7 to b624a18 Compare December 29, 2025 11:56
@rustbot

This comment has been minimized.

@Wilfred Wilfred force-pushed the fix_cycle_projections branch from b624a18 to 6e4df21 Compare January 6, 2026 12:08
@Wilfred Wilfred changed the title Fix lowering with supertrait predicates fix: Lowering crash with supertrait predicates Jan 6, 2026
@Wilfred Wilfred force-pushed the fix_cycle_projections branch from 6e4df21 to 1cd2211 Compare January 9, 2026 16:53
@Wilfred
Copy link
Contributor Author

Wilfred commented Jan 9, 2026

OK, I think this code is good to go now. Let me know what you think.

Copy link
Contributor

@ChayimFriedman2 ChayimFriedman2 left a comment

Choose a reason for hiding this comment

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

LGTM, minus one nit. Also rebase.

Previously both valid and invalid Rust code could crash r-a due to a
cyclic query during lowering.
@Wilfred Wilfred force-pushed the fix_cycle_projections branch from 1cd2211 to 236e2db Compare January 12, 2026 11:17
@Wilfred
Copy link
Contributor Author

Wilfred commented Jan 12, 2026

Rebased and resolved all comments :)

Copy link
Contributor

@ChayimFriedman2 ChayimFriedman2 left a comment

Choose a reason for hiding this comment

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

Thanks!

@ChayimFriedman2 ChayimFriedman2 added this pull request to the merge queue Jan 12, 2026
Merged via the queue into rust-lang:master with commit ae4a262 Jan 12, 2026
15 checks passed
@rustbot rustbot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jan 12, 2026
@Wilfred Wilfred deleted the fix_cycle_projections branch January 12, 2026 13:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cyclic dependency graph when parsing OPAQUE-KE v4.0.1

3 participants