1
Fork 0

Make confusable suggestions verbose

This commit is contained in:
Esteban Küber 2024-02-10 03:37:08 +00:00
parent 385eea1d46
commit e1e4da2b0a
14 changed files with 126 additions and 43 deletions

View file

@ -5,7 +5,12 @@ LL | fn owned(self: Box<Self>);
| --------- the method might not be found because of this arbitrary self type
...
LL | x.owned();
| ^^^^^ help: there is a method with a similar name: `to_owned`
| ^^^^^
|
help: there is a method with a similar name
|
LL | x.to_owned();
| ~~~~~~~~
error[E0599]: no method named `owned` found for mutable reference `&mut dyn Foo` in the current scope
--> $DIR/object-pointer-types.rs:17:7