diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/test/ui/methods/issues/issue-105732.rs | 3 | ||||
| -rw-r--r-- | src/test/ui/methods/issues/issue-105732.stderr | 16 |
2 files changed, 5 insertions, 14 deletions
diff --git a/src/test/ui/methods/issues/issue-105732.rs b/src/test/ui/methods/issues/issue-105732.rs index 98b7a8d0d04..d7005065813 100644 --- a/src/test/ui/methods/issues/issue-105732.rs +++ b/src/test/ui/methods/issues/issue-105732.rs @@ -6,7 +6,8 @@ auto trait Foo { trait Bar { fn f(&self) { - self.g(); //~ ERROR the method `g` exists for reference `&Self`, but its trait bounds were not satisfied + // issue #105788 + self.g(); //~ ERROR no method named `g` found for reference `&Self` in the current scope } } diff --git a/src/test/ui/methods/issues/issue-105732.stderr b/src/test/ui/methods/issues/issue-105732.stderr index fb2bdf47de7..7696642548d 100644 --- a/src/test/ui/methods/issues/issue-105732.stderr +++ b/src/test/ui/methods/issues/issue-105732.stderr @@ -6,21 +6,11 @@ LL | auto trait Foo { LL | fn g(&self); | ---^-------- help: remove these associated items -error[E0599]: the method `g` exists for reference `&Self`, but its trait bounds were not satisfied - --> $DIR/issue-105732.rs:9:14 +error[E0599]: no method named `g` found for reference `&Self` in the current scope + --> $DIR/issue-105732.rs:10:14 | LL | self.g(); - | ^ - | - = note: the following trait bounds were not satisfied: - `Self: Foo` - which is required by `&Self: Foo` - `&Self: Foo` - = help: items from traits can only be used if the type parameter is bounded by the trait -help: the following trait defines an item `g`, perhaps you need to add a supertrait for it: - | -LL | trait Bar: Foo { - | +++++ + | ^ help: there is a method with a similar name: `f` error: aborting due to 2 previous errors |
