about summary refs log tree commit diff
path: root/compiler/rustc_trait_selection/src
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-07-18 08:09:01 +0200
committerGitHub <noreply@github.com>2024-07-18 08:09:01 +0200
commita13d7dbecf6ea190b1edb274702e09a6e42b7838 (patch)
treebd0d159699064e461cc4d08448c733b61f14f340 /compiler/rustc_trait_selection/src
parentb2b14deca5a098f4ec8083e4355439d35fbeb667 (diff)
parente38032fb3ad5736934ea1ff1ecc43e8af4c47a87 (diff)
downloadrust-a13d7dbecf6ea190b1edb274702e09a6e42b7838.tar.gz
rust-a13d7dbecf6ea190b1edb274702e09a6e42b7838.zip
Rollup merge of #127878 - estebank:assoc-item-removal, r=fmease
Fix associated item removal suggestion

We were previously telling people to write what was already there, instead of removal (treating it as a `help`). We now properly suggest to remove the code that needs to be removed.

```
error[E0229]: associated item constraints are not allowed here
  --> $DIR/E0229.rs:13:25
   |
LL | fn baz<I>(x: &<I as Foo<A = Bar>>::A) {}
   |                         ^^^^^^^ associated item constraint not allowed here
   |
help: consider removing this associated item binding
   |
LL - fn baz<I>(x: &<I as Foo<A = Bar>>::A) {}
LL + fn baz<I>(x: &<I as Foo>::A) {}
   |
```
Diffstat (limited to 'compiler/rustc_trait_selection/src')
0 files changed, 0 insertions, 0 deletions