-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Never say "Trait
is implemented for {type error}
"
#121803
Conversation
r? @spastorino rustbot has assigned @spastorino. Use r? to explicitly pick a reviewer |
compiler/rustc_trait_selection/src/traits/error_reporting/type_err_ctxt_ext.rs
Outdated
Show resolved
Hide resolved
If you're curious, this is because |
When a trait bound error occurs, we look for alternative types that would have made the bound succeed. For some reason `{type error}` sometimes would appear as a type that would do so. We now remove `{type error}` from the list in every case to avoid nonsensical `note`s.
1c131cb
to
dab3d5b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me when ci is finished
@bors r=compiler-errors |
@bors rollup=always |
…iaskrgr Rollup of 11 pull requests Successful merges: - rust-lang#111505 (Made `INVALID_DOC_ATTRIBUTES` lint deny by default) - rust-lang#120305 (Delete line if suggestion would replace it with an empty line) - rust-lang#121153 (Suggest removing superfluous semicolon when statements used as expression) - rust-lang#121497 (`-Znext-solver=coherence`: suggest increasing recursion limit) - rust-lang#121634 (Clarify behavior of slice prefix/suffix operations in case of equality) - rust-lang#121706 (match lowering: Remove hacky branch in sort_candidate) - rust-lang#121730 (Add profiling support to AIX) - rust-lang#121750 (match lowering: Separate the `bool` case from other integers in `TestKind`) - rust-lang#121803 (Never say "`Trait` is implemented for `{type error}`") - rust-lang#121811 (Move sanitizer ui tests to sanitizer directory) - rust-lang#121824 (Implement missing ABI structures in StableMIR) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#121803 - estebank:dont-mention-type-error-e0277, r=compiler-errors Never say "`Trait` is implemented for `{type error}`" When a trait bound error occurs, we look for alternative types that would have made the bound succeed. For some reason `{type error}` sometimes would appear as a type that would do so. We now remove `{type error}` from the list in every case to avoid nonsensical `note`s.
When a trait bound error occurs, we look for alternative types that would have made the bound succeed. For some reason
{type error}
sometimes would appear as a type that would do so.We now remove
{type error}
from the list in every case to avoid nonsensicalnote
s.