1 error[E0437]: type `bar` is not a member of trait `Foo`
2 --> $DIR/impl-wrong-item-for-trait.rs:30:5
5 | ^^^^^^^^^^^^^^^ not a member of trait `Foo`
7 error[E0323]: item `bar` is an associated const, which doesn't match its trait `Foo`
8 --> $DIR/impl-wrong-item-for-trait.rs:12:5
11 | -------------- item in trait
13 LL | const bar: u64 = 1;
14 | ^^^^^^^^^^^^^^^^^^^ does not match trait
16 error[E0046]: not all trait items implemented, missing: `bar`
17 --> $DIR/impl-wrong-item-for-trait.rs:10:1
20 | -------------- `bar` from trait
22 LL | impl Foo for FooConstForMethod {
23 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `bar` in implementation
25 error[E0324]: item `MY_CONST` is an associated method, which doesn't match its trait `Foo`
26 --> $DIR/impl-wrong-item-for-trait.rs:22:5
28 LL | const MY_CONST: u32;
29 | -------------------- item in trait
32 | ^^^^^^^^^^^^^^^^ does not match trait
34 error[E0046]: not all trait items implemented, missing: `MY_CONST`
35 --> $DIR/impl-wrong-item-for-trait.rs:19:1
37 LL | const MY_CONST: u32;
38 | -------------------- `MY_CONST` from trait
40 LL | impl Foo for FooMethodForConst {
41 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `MY_CONST` in implementation
43 error[E0325]: item `bar` is an associated type, which doesn't match its trait `Foo`
44 --> $DIR/impl-wrong-item-for-trait.rs:30:5
47 | -------------- item in trait
50 | ^^^^^^^^^^^^^^^ does not match trait
52 error[E0046]: not all trait items implemented, missing: `bar`
53 --> $DIR/impl-wrong-item-for-trait.rs:28:1
56 | -------------- `bar` from trait
58 LL | impl Foo for FooTypeForMethod {
59 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `bar` in implementation
61 error[E0046]: not all trait items implemented, missing: `fmt`
62 --> $DIR/impl-wrong-item-for-trait.rs:36:1
64 LL | impl Debug for FooTypeForMethod {
65 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `fmt` in implementation
67 = help: implement the missing item: `fn fmt(&self, _: &mut Formatter<'_>) -> Result<(), std::fmt::Error> { todo!() }`
69 error: aborting due to 8 previous errors
71 Some errors have detailed explanations: E0046, E0323, E0324, E0325, E0437.
72 For more information about an error, try `rustc --explain E0046`.