]> git.lizzy.rs Git - rust.git/blob - src/test/ui/specialization/defaultimpl/specialization-trait-not-implemented.stderr
On single local candidate, use span label
[rust.git] / src / test / ui / specialization / defaultimpl / specialization-trait-not-implemented.stderr
1 error[E0599]: no method named `foo_one` found for struct `MyStruct` in the current scope
2   --> $DIR/specialization-trait-not-implemented.rs:22:29
3    |
4 LL | trait Foo {
5    | --------- this trait defines an item `foo_one`
6 ...
7 LL | struct MyStruct;
8    | ----------------
9    | |
10    | method `foo_one` not found for this
11    | this type doesn't satisfy the bound `Foo`
12 ...
13 LL |     println!("{}", MyStruct.foo_one());
14    |                             ^^^^^^^ method not found in `MyStruct`
15    |
16    = note: the method `foo_one` exists but the following trait bounds were not satisfied:
17            `MyStruct: Foo`
18    = help: items from traits can only be used if the trait is implemented and in scope
19
20 error: aborting due to previous error
21
22 For more information about this error, try `rustc --explain E0599`.