Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mention similarly named associated type even if it's not clearly in supertrait #99147

Merged
merged 1 commit into from
Jul 11, 2022

Conversation

compiler-errors
Copy link
Member

Due to query cycle avoidance, we sometimes restrict the candidates in complain_about_assoc_type_not_found too much so that we can't detect typo replacements from just supertraits.

This creates a more general note of the existence of a similarly named associated type from all visible traits when possible.

Fixes #55673

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Jul 11, 2022
@rust-highfive
Copy link
Contributor

r? @lcnr

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jul 11, 2022
@lcnr
Copy link
Contributor

lcnr commented Jul 11, 2022

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Jul 11, 2022

📌 Commit 680fef4 has been approved by lcnr

It is now in the queue for this repository.

@bors bors 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 Jul 11, 2022
Dylan-DPC added a commit to Dylan-DPC/rust that referenced this pull request Jul 11, 2022
Mention similarly named associated type even if it's not clearly in supertrait

Due to query cycle avoidance, we sometimes restrict the candidates in `complain_about_assoc_type_not_found` too much so that we can't detect typo replacements from just supertraits.

This creates a more general note of the existence of a similarly named associated type from _all_ visible traits when possible.

Fixes rust-lang#55673
bors added a commit to rust-lang-ci/rust that referenced this pull request Jul 11, 2022
Rollup of 5 pull requests

Successful merges:

 - rust-lang#98882 (explain doc comments in macros a bit)
 - rust-lang#98907 (Deny float const params even when `adt_const_params` is enabled)
 - rust-lang#99091 (Do not mention private types from other crates as impl candidates)
 - rust-lang#99140 (Implement `SourceMap::is_span_accessible`)
 - rust-lang#99147 (Mention similarly named associated type even if it's not clearly in supertrait)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 21d6b1f into rust-lang:master Jul 11, 2022
@rustbot rustbot added this to the 1.64.0 milestone Jul 11, 2022
@compiler-errors compiler-errors deleted the issue-55673 branch August 11, 2023 20:05
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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Associated type not found error does not attempt to suggest typoed names
5 participants