Skip to content

Conversation

samueltardieu
Copy link
Member

@samueltardieu samueltardieu commented Jun 4, 2025

clippy_utils::ty::InteriorMut::interior_mut_ty_chain must stop recursing forever when types are chained indefinitely due to the use of associated types in generics. A false negative is acceptable, and documented here.

Should this situation be later identified specifically, a conversion of Option to Result would allow separating the infinitely recursive case from a negative one.

changelog: [mutable_key_type]: fix ICE when infinitely associated generic types are used

Fixes #14935

@rustbot
Copy link
Collaborator

rustbot commented Jun 4, 2025

r? @llogiq

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

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Jun 4, 2025
`clippy_utils::ty::InteriorMut::interior_mut_ty_chain` must stop
recursing forever when types are chained indefinitely due to the use of
associated types in generics. A false negative is acceptable, and
documented here.

Should this situation be later identified specifically, a conversion of
`Option` to `Result` would allow separating the infinitely recursive
case from a negative one.
@llogiq
Copy link
Contributor

llogiq commented Jun 5, 2025

Thank you!

@llogiq llogiq added this pull request to the merge queue Jun 5, 2025
Merged via the queue into rust-lang:master with commit da93448 Jun 5, 2025
11 checks passed
@samueltardieu samueltardieu deleted the issue-14935 branch June 5, 2025 23:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Stack overflow when using recursive type and conditions

3 participants