]>
Commit | Line | Data |
---|---|---|
2b03887a | 1 | error: `Self` is not valid in the self type of an impl block |
487cf647 | 2 | --> $DIR/resolve-self-in-impl.rs:16:6 |
b7449926 | 3 | | |
487cf647 FG |
4 | LL | impl Self {} |
5 | | ^^^^ | |
b7449926 | 6 | | |
2b03887a | 7 | = note: replace `Self` with a different type |
b7449926 | 8 | |
2b03887a | 9 | error: `Self` is not valid in the self type of an impl block |
487cf647 | 10 | --> $DIR/resolve-self-in-impl.rs:17:8 |
b7449926 | 11 | | |
487cf647 FG |
12 | LL | impl S<Self> {} |
13 | | ^^^^ | |
b7449926 | 14 | | |
2b03887a | 15 | = note: replace `Self` with a different type |
b7449926 | 16 | |
2b03887a | 17 | error: `Self` is not valid in the self type of an impl block |
487cf647 | 18 | --> $DIR/resolve-self-in-impl.rs:18:7 |
b7449926 | 19 | | |
487cf647 FG |
20 | LL | impl (Self, Self) {} |
21 | | ^^^^ ^^^^ | |
b7449926 | 22 | | |
2b03887a | 23 | = note: replace `Self` with a different type |
b7449926 | 24 | |
2b03887a | 25 | error: `Self` is not valid in the self type of an impl block |
487cf647 | 26 | --> $DIR/resolve-self-in-impl.rs:14:13 |
b7449926 | 27 | | |
487cf647 FG |
28 | LL | impl Tr for Self {} |
29 | | ^^^^ | |
b7449926 | 30 | | |
2b03887a FG |
31 | = note: replace `Self` with a different type |
32 | ||
33 | error: `Self` is not valid in the self type of an impl block | |
487cf647 | 34 | --> $DIR/resolve-self-in-impl.rs:15:15 |
0731742a | 35 | | |
487cf647 FG |
36 | LL | impl Tr for S<Self> {} |
37 | | ^^^^ | |
2b03887a FG |
38 | | |
39 | = note: replace `Self` with a different type | |
b7449926 | 40 | |
2b03887a FG |
41 | error[E0391]: cycle detected when computing trait implemented by `<impl at $DIR/resolve-self-in-impl.rs:19:1: 19:23>` |
42 | --> $DIR/resolve-self-in-impl.rs:19:1 | |
b7449926 | 43 | | |
532ac7d7 | 44 | LL | impl Tr<Self::A> for S {} |
b7449926 XL |
45 | | ^^^^^^^^^^^^^^^^^^^^^^ |
46 | | | |
2b03887a | 47 | = note: ...which immediately requires computing trait implemented by `<impl at $DIR/resolve-self-in-impl.rs:19:1: 19:23>` again |
0731742a XL |
48 | note: cycle used when collecting item types in top-level module |
49 | --> $DIR/resolve-self-in-impl.rs:1:1 | |
50 | | | |
51 | LL | / #![feature(associated_type_defaults)] | |
52 | LL | | | |
53 | LL | | struct S<T = u8>(T); | |
54 | LL | | trait Tr<T = u8> { | |
55 | ... | | |
56 | LL | | | |
57 | LL | | fn main() {} | |
58 | | |____________^ | |
b7449926 | 59 | |
2b03887a | 60 | error: aborting due to 6 previous errors |
b7449926 XL |
61 | |
62 | For more information about this error, try `rustc --explain E0391`. |