about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2025-02-28 21:39:25 +0000
committerEsteban Küber <esteban@kuber.com.ar>2025-03-03 18:23:49 +0000
commita23566a57e4d53a35827becc2f65ce27951276c8 (patch)
tree02d9eecc0a3c126b4ebba69587eb7287c5d57f18 /compiler/rustc_codegen_llvm/src
parent81d8edc2000aa38b08ad09fce22d90f1990b6459 (diff)
downloadrust-a23566a57e4d53a35827becc2f65ce27951276c8.tar.gz
rust-a23566a57e4d53a35827becc2f65ce27951276c8.zip
Provide more context on resolve error caused from incorrect RTN
When encountering a resolve E0575 error for an associated method (when a type was expected), see if it could have been an intended return type notation bound.

```
error[E0575]: expected associated type, found associated function `Trait::method`
  --> $DIR/bad-inputs-and-output.rs:31:36
   |
LL | fn foo_qualified<T: Trait>() where <T as Trait>::method(i32): Send {}
   |                                    ^^^^^^^^^^^^^^^^^^^^^^^^^ not a associated type
   |
help: you might have meant to use the return type notation syntax
   |
LL - fn foo_qualified<T: Trait>() where <T as Trait>::method(i32): Send {}
LL + fn foo_qualified<T: Trait>() where T::method(..): Send {}
   |
```
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
0 files changed, 0 insertions, 0 deletions