]> git.lizzy.rs Git - rust.git/blob - src/test/ui/specialization/defaultimpl/specialization-trait-not-implemented.stderr
keep predicate order and tweak output
[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 | struct MyStruct;
5    | ----------------
6    | |
7    | method `foo_one` not found for this
8    | doesn't satisfy `MyStruct: Foo`
9 ...
10 LL |     println!("{}", MyStruct.foo_one());
11    |                             ^^^^^^^ method not found in `MyStruct`
12    |
13    = note: the method `foo_one` exists but the following trait bounds were not satisfied:
14            `MyStruct: Foo`
15    = help: items from traits can only be used if the trait is implemented and in scope
16 note: `Foo` defines an item `foo_one`, perhaps you need to implement it
17   --> $DIR/specialization-trait-not-implemented.rs:7:1
18    |
19 LL | trait Foo {
20    | ^^^^^^^^^
21
22 error: aborting due to previous error
23
24 For more information about this error, try `rustc --explain E0599`.