1
+ error: `Self` is only available in impls, traits, and type definitions
2
+ --> $DIR/resolve-self-in-impl.rs:14:13
3
+ |
4
+ LL | impl Tr for Self {}
5
+ | ^^^^
6
+
7
+ error: `Self` is only available in impls, traits, and type definitions
8
+ --> $DIR/resolve-self-in-impl.rs:16:15
9
+ |
10
+ LL | impl Tr for S<Self> {}
11
+ | ^^^^
12
+
13
+ error: `Self` is only available in impls, traits, and type definitions
14
+ --> $DIR/resolve-self-in-impl.rs:18:6
15
+ |
16
+ LL | impl Self {}
17
+ | ^^^^
18
+
19
+ error: `Self` is only available in impls, traits, and type definitions
20
+ --> $DIR/resolve-self-in-impl.rs:20:8
21
+ |
22
+ LL | impl S<Self> {}
23
+ | ^^^^
24
+
1
25
error[E0391]: cycle detected when computing type of `<impl at $DIR/resolve-self-in-impl.rs:14:1: 14:20>`
2
26
--> $DIR/resolve-self-in-impl.rs:14:13
3
27
|
@@ -17,13 +41,13 @@ LL | |
17
41
LL | | fn main() {}
18
42
| |____________^
19
43
20
- error[E0391]: cycle detected when computing type of `<impl at $DIR/resolve-self-in-impl.rs:15 :1: 15 :23>`
21
- --> $DIR/resolve-self-in-impl.rs:15 :15
44
+ error[E0391]: cycle detected when computing type of `<impl at $DIR/resolve-self-in-impl.rs:16 :1: 16 :23>`
45
+ --> $DIR/resolve-self-in-impl.rs:16 :15
22
46
|
23
47
LL | impl Tr for S<Self> {}
24
48
| ^^^^
25
49
|
26
- = note: ...which immediately requires computing type of `<impl at $DIR/resolve-self-in-impl.rs:15 :1: 15 :23>` again
50
+ = note: ...which immediately requires computing type of `<impl at $DIR/resolve-self-in-impl.rs:16 :1: 16 :23>` again
27
51
note: cycle used when collecting item types in top-level module
28
52
--> $DIR/resolve-self-in-impl.rs:1:1
29
53
|
@@ -36,13 +60,13 @@ LL | |
36
60
LL | | fn main() {}
37
61
| |____________^
38
62
39
- error[E0391]: cycle detected when computing type of `<impl at $DIR/resolve-self-in-impl.rs:16 :1: 16 :13>`
40
- --> $DIR/resolve-self-in-impl.rs:16 :6
63
+ error[E0391]: cycle detected when computing type of `<impl at $DIR/resolve-self-in-impl.rs:18 :1: 18 :13>`
64
+ --> $DIR/resolve-self-in-impl.rs:18 :6
41
65
|
42
66
LL | impl Self {}
43
67
| ^^^^
44
68
|
45
- = note: ...which immediately requires computing type of `<impl at $DIR/resolve-self-in-impl.rs:16 :1: 16 :13>` again
69
+ = note: ...which immediately requires computing type of `<impl at $DIR/resolve-self-in-impl.rs:18 :1: 18 :13>` again
46
70
note: cycle used when collecting item types in top-level module
47
71
--> $DIR/resolve-self-in-impl.rs:1:1
48
72
|
@@ -55,13 +79,13 @@ LL | |
55
79
LL | | fn main() {}
56
80
| |____________^
57
81
58
- error[E0391]: cycle detected when computing type of `<impl at $DIR/resolve-self-in-impl.rs:17 :1: 17 :16>`
59
- --> $DIR/resolve-self-in-impl.rs:17 :8
82
+ error[E0391]: cycle detected when computing type of `<impl at $DIR/resolve-self-in-impl.rs:20 :1: 20 :16>`
83
+ --> $DIR/resolve-self-in-impl.rs:20 :8
60
84
|
61
85
LL | impl S<Self> {}
62
86
| ^^^^
63
87
|
64
- = note: ...which immediately requires computing type of `<impl at $DIR/resolve-self-in-impl.rs:17 :1: 17 :16>` again
88
+ = note: ...which immediately requires computing type of `<impl at $DIR/resolve-self-in-impl.rs:20 :1: 20 :16>` again
65
89
note: cycle used when collecting item types in top-level module
66
90
--> $DIR/resolve-self-in-impl.rs:1:1
67
91
|
@@ -74,13 +98,13 @@ LL | |
74
98
LL | | fn main() {}
75
99
| |____________^
76
100
77
- error[E0391]: cycle detected when computing trait implemented by `<impl at $DIR/resolve-self-in-impl.rs:18 :1: 18 :26>`
78
- --> $DIR/resolve-self-in-impl.rs:18 :1
101
+ error[E0391]: cycle detected when computing trait implemented by `<impl at $DIR/resolve-self-in-impl.rs:22 :1: 22 :26>`
102
+ --> $DIR/resolve-self-in-impl.rs:22 :1
79
103
|
80
104
LL | impl Tr<Self::A> for S {}
81
105
| ^^^^^^^^^^^^^^^^^^^^^^
82
106
|
83
- = note: ...which immediately requires computing trait implemented by `<impl at $DIR/resolve-self-in-impl.rs:18 :1: 18 :26>` again
107
+ = note: ...which immediately requires computing trait implemented by `<impl at $DIR/resolve-self-in-impl.rs:22 :1: 22 :26>` again
84
108
note: cycle used when collecting item types in top-level module
85
109
--> $DIR/resolve-self-in-impl.rs:1:1
86
110
|
@@ -93,6 +117,6 @@ LL | |
93
117
LL | | fn main() {}
94
118
| |____________^
95
119
96
- error: aborting due to 5 previous errors
120
+ error: aborting due to 9 previous errors
97
121
98
122
For more information about this error, try `rustc --explain E0391`.
0 commit comments