• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1error: unexpected token in attribute
2 --> tests/ui/pin_project/invalid.rs:8:14
3  |
48 |         #[pin()] //~ ERROR unexpected token in attribute
5  |              ^
6
7error: unexpected token in attribute
8  --> tests/ui/pin_project/invalid.rs:13:29
9   |
1013 |     struct TupleStruct(#[pin(foo)] ()); //~ ERROR unexpected token in attribute
11   |                             ^
12
13error: unexpected token in attribute
14  --> tests/ui/pin_project/invalid.rs:17:16
15   |
1617 |         V(#[pin(foo)] ()), //~ ERROR unexpected token in attribute
17   |                ^
18
19error: unexpected token in attribute
20  --> tests/ui/pin_project/invalid.rs:23:18
21   |
2223 |             #[pin(foo)] //~ ERROR unexpected token in attribute
23   |                  ^
24
25error: duplicate #[pin] attribute
26  --> tests/ui/pin_project/invalid.rs:35:9
27   |
2835 |         #[pin] //~ ERROR duplicate #[pin] attribute
29   |         ^^^^^^
30
31error: duplicate #[pin] attribute
32  --> tests/ui/pin_project/invalid.rs:42:9
33   |
3442 |         #[pin]
35   |         ^^^^^^
36
37error: duplicate #[pin] attribute
38  --> tests/ui/pin_project/invalid.rs:51:13
39   |
4051 |             #[pin]
41   |             ^^^^^^
42
43error: duplicate #[pin] attribute
44  --> tests/ui/pin_project/invalid.rs:61:13
45   |
4661 |             #[pin] //~ ERROR duplicate #[pin] attribute
47   |             ^^^^^^
48
49error: #[pin] attribute may only be used on fields of structs or variants
50  --> tests/ui/pin_project/invalid.rs:71:5
51   |
5271 |     #[pin] //~ ERROR may only be used on fields of structs or variants
53   |     ^^^^^^
54
55error: #[pin] attribute may only be used on fields of structs or variants
56  --> tests/ui/pin_project/invalid.rs:79:9
57   |
5879 |         #[pin] //~ ERROR may only be used on fields of structs or variants
59   |         ^^^^^^
60
61error: #[pin] attribute may only be used on fields of structs or variants
62  --> tests/ui/pin_project/invalid.rs:84:5
63   |
6484 |     #[pin] //~ ERROR may only be used on fields of structs or variants
65   |     ^^^^^^
66
67error: `Replace` argument was removed, use `project_replace` argument instead
68  --> tests/ui/pin_project/invalid.rs:93:19
69   |
7093 |     #[pin_project(Replace)] //~ ERROR `Replace` argument was removed, use `project_replace` argument instead
71   |                   ^^^^^^^
72
73error: expected identifier
74  --> tests/ui/pin_project/invalid.rs:96:31
75   |
7696 |     #[pin_project(UnsafeUnpin,,)] //~ ERROR expected identifier
77   |                               ^
78
79error: unexpected argument: Foo
80  --> tests/ui/pin_project/invalid.rs:99:19
81   |
8299 |     #[pin_project(Foo)] //~ ERROR unexpected argument
83   |                   ^^^
84
85error: expected identifier
86   --> tests/ui/pin_project/invalid.rs:102:19
87    |
88102 |     #[pin_project(,UnsafeUnpin)] //~ ERROR expected identifier
89    |                   ^
90
91error: expected `,`
92   --> tests/ui/pin_project/invalid.rs:108:30
93    |
94108 |     #[pin_project(PinnedDrop PinnedDrop)] //~ ERROR expected `,`
95    |                              ^^^^^^^^^^
96
97error: duplicate `PinnedDrop` argument
98   --> tests/ui/pin_project/invalid.rs:111:31
99    |
100111 |     #[pin_project(PinnedDrop, PinnedDrop)] //~ ERROR duplicate `PinnedDrop` argument
101    |                               ^^^^^^^^^^
102
103error: duplicate `UnsafeUnpin` argument
104   --> tests/ui/pin_project/invalid.rs:114:32
105    |
106114 |     #[pin_project(UnsafeUnpin, UnsafeUnpin)] //~ ERROR duplicate `UnsafeUnpin` argument
107    |                                ^^^^^^^^^^^
108
109error: duplicate `!Unpin` argument
110   --> tests/ui/pin_project/invalid.rs:117:27
111    |
112117 |     #[pin_project(!Unpin, !Unpin)] //~ ERROR duplicate `!Unpin` argument
113    |                           ^^^^^^
114
115error: duplicate `UnsafeUnpin` argument
116   --> tests/ui/pin_project/invalid.rs:120:44
117    |
118120 |     #[pin_project(PinnedDrop, UnsafeUnpin, UnsafeUnpin)] //~ ERROR duplicate `UnsafeUnpin` argument
119    |                                            ^^^^^^^^^^^
120
121error: duplicate `PinnedDrop` argument
122   --> tests/ui/pin_project/invalid.rs:123:44
123    |
124123 |     #[pin_project(PinnedDrop, UnsafeUnpin, PinnedDrop, UnsafeUnpin)] //~ ERROR duplicate `PinnedDrop` argument
125    |                                            ^^^^^^^^^^
126
127error: duplicate `project` argument
128   --> tests/ui/pin_project/invalid.rs:126:32
129    |
130126 |     #[pin_project(project = A, project = B)] //~ ERROR duplicate `project` argument
131    |                                ^^^^^^^^^^^
132
133error: duplicate `project` argument
134   --> tests/ui/pin_project/invalid.rs:129:49
135    |
136129 |     #[pin_project(project = A, project_ref = A, project = B)] //~ ERROR duplicate `project` argument
137    |                                                 ^^^^^^^^^^^
138
139error: duplicate `project_ref` argument
140   --> tests/ui/pin_project/invalid.rs:132:36
141    |
142132 |     #[pin_project(project_ref = A, project_ref = B)] //~ ERROR duplicate `project_ref` argument
143    |                                    ^^^^^^^^^^^^^^^
144
145error: duplicate `project_replace` argument
146   --> tests/ui/pin_project/invalid.rs:135:40
147    |
148135 |     #[pin_project(project_replace = A, project_replace = B)] //~ ERROR duplicate `project_replace` argument
149    |                                        ^^^^^^^^^^^^^^^^^^^
150
151error: duplicate `project_replace` argument
152   --> tests/ui/pin_project/invalid.rs:138:36
153    |
154138 |     #[pin_project(project_replace, project_replace = B)] //~ ERROR duplicate `project_replace` argument
155    |                                    ^^^^^^^^^^^^^^^^^^^
156
157error: duplicate `project_replace` argument
158   --> tests/ui/pin_project/invalid.rs:141:40
159    |
160141 |     #[pin_project(project_replace = A, project_replace)] //~ ERROR duplicate `project_replace` argument
161    |                                        ^^^^^^^^^^^^^^^
162
163error: arguments `PinnedDrop` and `project_replace` are mutually exclusive
164   --> tests/ui/pin_project/invalid.rs:147:19
165    |
166147 |     #[pin_project(PinnedDrop, project_replace)] //~ ERROR arguments `PinnedDrop` and `project_replace` are mutually exclusive
167    |                   ^^^^^^^^^^
168
169error: arguments `PinnedDrop` and `project_replace` are mutually exclusive
170   --> tests/ui/pin_project/invalid.rs:150:49
171    |
172150 |     #[pin_project(project_replace, UnsafeUnpin, PinnedDrop)] //~ ERROR arguments `PinnedDrop` and `project_replace` are mutually exclusive
173    |                                                 ^^^^^^^^^^
174
175error: arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
176   --> tests/ui/pin_project/invalid.rs:153:19
177    |
178153 |     #[pin_project(UnsafeUnpin, !Unpin)] //~ ERROR arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
179    |                   ^^^^^^^^^^^
180
181error: arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
182   --> tests/ui/pin_project/invalid.rs:156:39
183    |
184156 |     #[pin_project(!Unpin, PinnedDrop, UnsafeUnpin)] //~ ERROR arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
185    |                                       ^^^^^^^^^^^
186
187error: expected `!Unpin`, found `!`
188   --> tests/ui/pin_project/invalid.rs:159:19
189    |
190159 |     #[pin_project(!)] //~ ERROR expected `!Unpin`, found `!`
191    |                   ^
192
193error: unexpected argument: Unpin
194   --> tests/ui/pin_project/invalid.rs:162:19
195    |
196162 |     #[pin_project(Unpin)] //~ ERROR unexpected argument
197    |                   ^^^^^
198
199error: expected `project = <identifier>`, found `project`
200   --> tests/ui/pin_project/invalid.rs:165:19
201    |
202165 |     #[pin_project(project)] //~ ERROR expected `project = <identifier>`, found `project`
203    |                   ^^^^^^^
204
205error: expected `project = <identifier>`, found `project =`
206   --> tests/ui/pin_project/invalid.rs:168:19
207    |
208168 |     #[pin_project(project = )] //~ ERROR expected `project = <identifier>`, found `project =`
209    |                   ^^^^^^^^^
210
211error: expected identifier
212   --> tests/ui/pin_project/invalid.rs:171:29
213    |
214171 |     #[pin_project(project = !)] //~ ERROR expected identifier
215    |                             ^
216
217error: expected `project_ref = <identifier>`, found `project_ref`
218   --> tests/ui/pin_project/invalid.rs:174:19
219    |
220174 |     #[pin_project(project_ref)] //~ ERROR expected `project_ref = <identifier>`, found `project_ref`
221    |                   ^^^^^^^^^^^
222
223error: expected `project_ref = <identifier>`, found `project_ref =`
224   --> tests/ui/pin_project/invalid.rs:177:19
225    |
226177 |     #[pin_project(project_ref = )] //~ ERROR expected `project_ref = <identifier>`, found `project_ref =`
227    |                   ^^^^^^^^^^^^^
228
229error: expected identifier
230   --> tests/ui/pin_project/invalid.rs:180:33
231    |
232180 |     #[pin_project(project_ref = !)] //~ ERROR expected identifier
233    |                                 ^
234
235error: expected `project_replace = <identifier>`, found `project_replace =`
236   --> tests/ui/pin_project/invalid.rs:186:19
237    |
238186 |     #[pin_project(project_replace = )] //~ ERROR expected `project_replace = <identifier>`, found `project_replace =`
239    |                   ^^^^^^^^^^^^^^^^^
240
241error: expected identifier
242   --> tests/ui/pin_project/invalid.rs:189:37
243    |
244189 |     #[pin_project(project_replace = !)] //~ ERROR expected identifier
245    |                                     ^
246
247error: `project_replace` argument requires a value when used on enums
248   --> tests/ui/pin_project/invalid.rs:192:19
249    |
250192 |     #[pin_project(project_replace)] //~ ERROR `project_replace` argument requires a value when used on enums
251    |                   ^^^^^^^^^^^^^^^
252
253error: name `OrigAndProj` is the same as the original type name
254   --> tests/ui/pin_project/invalid.rs:201:29
255    |
256201 |     #[pin_project(project = OrigAndProj)] //~ ERROR name `OrigAndProj` is the same as the original type name
257    |                             ^^^^^^^^^^^
258
259error: name `OrigAndProjRef` is the same as the original type name
260   --> tests/ui/pin_project/invalid.rs:204:33
261    |
262204 |     #[pin_project(project_ref = OrigAndProjRef)] //~ ERROR name `OrigAndProjRef` is the same as the original type name
263    |                                 ^^^^^^^^^^^^^^
264
265error: name `OrigAndProjOwn` is the same as the original type name
266   --> tests/ui/pin_project/invalid.rs:207:37
267    |
268207 |     #[pin_project(project_replace = OrigAndProjOwn)] //~ ERROR name `OrigAndProjOwn` is the same as the original type name
269    |                                     ^^^^^^^^^^^^^^
270
271error: name `A` is already specified by `project` argument
272   --> tests/ui/pin_project/invalid.rs:210:46
273    |
274210 |     #[pin_project(project = A, project_ref = A)] //~ ERROR name `A` is already specified by `project` argument
275    |                                              ^
276
277error: name `A` is already specified by `project` argument
278   --> tests/ui/pin_project/invalid.rs:213:50
279    |
280213 |     #[pin_project(project = A, project_replace = A)] //~ ERROR name `A` is already specified by `project` argument
281    |                                                  ^
282
283error: name `A` is already specified by `project_ref` argument
284   --> tests/ui/pin_project/invalid.rs:216:54
285    |
286216 |     #[pin_project(project_ref = A, project_replace = A)] //~ ERROR name `A` is already specified by `project_ref` argument
287    |                                                      ^
288
289error: duplicate #[pin_project] attribute
290   --> tests/ui/pin_project/invalid.rs:224:5
291    |
292224 |     #[pin_project] //~ ERROR duplicate #[pin_project] attribute
293    |     ^^^^^^^^^^^^^^
294
295error: #[pin_project] attribute may not be used on structs with zero fields
296   --> tests/ui/pin_project/invalid.rs:232:19
297    |
298232 |     struct Struct {} //~ ERROR may not be used on structs with zero fields
299    |                   ^^
300
301error: #[pin_project] attribute may not be used on structs with zero fields
302   --> tests/ui/pin_project/invalid.rs:235:23
303    |
304235 |     struct TupleStruct(); //~ ERROR may not be used on structs with zero fields
305    |                       ^^
306
307error: #[pin_project] attribute may not be used on structs with zero fields
308   --> tests/ui/pin_project/invalid.rs:238:12
309    |
310238 |     struct UnitStruct; //~ ERROR may not be used on structs with zero fields
311    |            ^^^^^^^^^^
312
313error: #[pin_project] attribute may not be used on enums without variants
314   --> tests/ui/pin_project/invalid.rs:241:20
315    |
316241 |     enum EnumEmpty {} //~ ERROR may not be used on enums without variants
317    |                    ^^
318
319error: #[pin_project] attribute may not be used on enums with discriminants
320   --> tests/ui/pin_project/invalid.rs:245:13
321    |
322245 |         V = 2, //~ ERROR may not be used on enums with discriminants
323    |             ^
324
325error: #[pin_project] attribute may not be used on enums with zero fields
326   --> tests/ui/pin_project/invalid.rs:250:9
327    |
328250 | /         Unit, //~ ERROR may not be used on enums with zero fields
329251 | |         Tuple(),
330252 | |         Struct {},
331    | |__________________^
332
333error: #[pin_project] attribute may only be used on structs or enums
334   --> tests/ui/pin_project/invalid.rs:256:5
335    |
336256 | /     union Union {
337257 | |         //~^ ERROR may only be used on structs or enums
338258 | |         f: (),
339259 | |     }
340    | |_____^
341
342error: #[pin_project] attribute may only be used on structs or enums
343   --> tests/ui/pin_project/invalid.rs:262:5
344    |
345262 |     impl Impl {} //~ ERROR may only be used on structs or enums
346    |     ^^^^^^^^^^^^
347
348error: #[pin_project] attribute may not be used on #[repr(packed)] types
349   --> tests/ui/pin_project/invalid.rs:270:12
350    |
351270 |     #[repr(packed)]
352    |            ^^^^^^
353
354error: #[pin_project] attribute may not be used on #[repr(packed)] types
355   --> tests/ui/pin_project/invalid.rs:274:12
356    |
357274 |     #[repr(packed)]
358    |            ^^^^^^
359
360error: #[pin_project] attribute may not be used on #[repr(packed)] types
361   --> tests/ui/pin_project/invalid.rs:278:12
362    |
363278 |     #[repr(packed)]
364    |            ^^^^^^
365