When encountering method on Self that we can't suggest, mention it

This commit is contained in:
Esteban Küber 2023-09-23 01:47:06 +00:00
parent c4a4926083
commit 0e98682576
2 changed files with 31 additions and 30 deletions

View file

@ -12,6 +12,9 @@ LL | Self::foo();
error[E0425]: cannot find function `bar` in this scope
--> $DIR/assoc_fn_without_self.rs:17:9
|
LL | fn bar(&self) {}
| --- a method by that name is available on `Self` here
...
LL | bar();
| ^^^ not found in this scope