Debian Codegraph @

third_party/rust/pin-project/tests/ui/pin_project/invalid.stderr

raw
1 error: unexpected token in attribute
2 --> tests/ui/pin_project/invalid.rs:6:14
3 |
4 6 | #[pin()] //~ ERROR unexpected token in attribute
5 | ^
6
7 error: unexpected token in attribute
8 --> tests/ui/pin_project/invalid.rs:11:29
9 |
10 11 | struct TupleStruct(#[pin(foo)] ()); //~ ERROR unexpected token in attribute
11 | ^
12
13 error: unexpected token in attribute
14 --> tests/ui/pin_project/invalid.rs:15:16
15 |
16 15 | V(#[pin(foo)] ()), //~ ERROR unexpected token in attribute
17 | ^
18
19 error: unexpected token in attribute
20 --> tests/ui/pin_project/invalid.rs:21:18
21 |
22 21 | #[pin(foo)] //~ ERROR unexpected token in attribute
23 | ^
24
25 error: duplicate #[pin] attribute
26 --> tests/ui/pin_project/invalid.rs:33:9
27 |
28 33 | #[pin] //~ ERROR duplicate #[pin] attribute
29 | ^^^^^^
30
31 error: duplicate #[pin] attribute
32 --> tests/ui/pin_project/invalid.rs:40:9
33 |
34 40 | #[pin]
35 | ^^^^^^
36
37 error: duplicate #[pin] attribute
38 --> tests/ui/pin_project/invalid.rs:49:13
39 |
40 49 | #[pin]
41 | ^^^^^^
42
43 error: duplicate #[pin] attribute
44 --> tests/ui/pin_project/invalid.rs:59:13
45 |
46 59 | #[pin] //~ ERROR duplicate #[pin] attribute
47 | ^^^^^^
48
49 error: #[pin] attribute may only be used on fields of structs or variants
50 --> tests/ui/pin_project/invalid.rs:69:5
51 |
52 69 | #[pin] //~ ERROR may only be used on fields of structs or variants
53 | ^^^^^^
54
55 error: #[pin] attribute may only be used on fields of structs or variants
56 --> tests/ui/pin_project/invalid.rs:77:9
57 |
58 77 | #[pin] //~ ERROR may only be used on fields of structs or variants
59 | ^^^^^^
60
61 error: #[pin] attribute may only be used on fields of structs or variants
62 --> tests/ui/pin_project/invalid.rs:82:5
63 |
64 82 | #[pin] //~ ERROR may only be used on fields of structs or variants
65 | ^^^^^^
66
67 error: `Replace` argument was removed, use `project_replace` argument instead
68 --> tests/ui/pin_project/invalid.rs:91:19
69 |
70 91 | #[pin_project(Replace)] //~ ERROR `Replace` argument was removed, use `project_replace` argument instead
71 | ^^^^^^^
72
73 error: expected identifier
74 --> tests/ui/pin_project/invalid.rs:94:31
75 |
76 94 | #[pin_project(UnsafeUnpin,,)] //~ ERROR expected identifier
77 | ^
78
79 error: unexpected argument: Foo
80 --> tests/ui/pin_project/invalid.rs:97:19
81 |
82 97 | #[pin_project(Foo)] //~ ERROR unexpected argument
83 | ^^^
84
85 error: expected identifier
86 --> tests/ui/pin_project/invalid.rs:100:19
87 |
88 100 | #[pin_project(,UnsafeUnpin)] //~ ERROR expected identifier
89 | ^
90
91 error: expected `,`
92 --> tests/ui/pin_project/invalid.rs:106:30
93 |
94 106 | #[pin_project(PinnedDrop PinnedDrop)] //~ ERROR expected `,`
95 | ^^^^^^^^^^
96
97 error: duplicate `PinnedDrop` argument
98 --> tests/ui/pin_project/invalid.rs:109:31
99 |
100 109 | #[pin_project(PinnedDrop, PinnedDrop)] //~ ERROR duplicate `PinnedDrop` argument
101 | ^^^^^^^^^^
102
103 error: duplicate `UnsafeUnpin` argument
104 --> tests/ui/pin_project/invalid.rs:112:32
105 |
106 112 | #[pin_project(UnsafeUnpin, UnsafeUnpin)] //~ ERROR duplicate `UnsafeUnpin` argument
107 | ^^^^^^^^^^^
108
109 error: duplicate `!Unpin` argument
110 --> tests/ui/pin_project/invalid.rs:115:27
111 |
112 115 | #[pin_project(!Unpin, !Unpin)] //~ ERROR duplicate `!Unpin` argument
113 | ^^^^^^
114
115 error: duplicate `UnsafeUnpin` argument
116 --> tests/ui/pin_project/invalid.rs:118:44
117 |
118 118 | #[pin_project(PinnedDrop, UnsafeUnpin, UnsafeUnpin)] //~ ERROR duplicate `UnsafeUnpin` argument
119 | ^^^^^^^^^^^
120
121 error: duplicate `PinnedDrop` argument
122 --> tests/ui/pin_project/invalid.rs:121:44
123 |
124 121 | #[pin_project(PinnedDrop, UnsafeUnpin, PinnedDrop, UnsafeUnpin)] //~ ERROR duplicate `PinnedDrop` argument
125 | ^^^^^^^^^^
126
127 error: duplicate `project` argument
128 --> tests/ui/pin_project/invalid.rs:124:32
129 |
130 124 | #[pin_project(project = A, project = B)] //~ ERROR duplicate `project` argument
131 | ^^^^^^^^^^^
132
133 error: duplicate `project` argument
134 --> tests/ui/pin_project/invalid.rs:127:49
135 |
136 127 | #[pin_project(project = A, project_ref = A, project = B)] //~ ERROR duplicate `project` argument
137 | ^^^^^^^^^^^
138
139 error: duplicate `project_ref` argument
140 --> tests/ui/pin_project/invalid.rs:130:36
141 |
142 130 | #[pin_project(project_ref = A, project_ref = B)] //~ ERROR duplicate `project_ref` argument
143 | ^^^^^^^^^^^^^^^
144
145 error: duplicate `project_replace` argument
146 --> tests/ui/pin_project/invalid.rs:133:40
147 |
148 133 | #[pin_project(project_replace = A, project_replace = B)] //~ ERROR duplicate `project_replace` argument
149 | ^^^^^^^^^^^^^^^^^^^
150
151 error: duplicate `project_replace` argument
152 --> tests/ui/pin_project/invalid.rs:136:36
153 |
154 136 | #[pin_project(project_replace, project_replace = B)] //~ ERROR duplicate `project_replace` argument
155 | ^^^^^^^^^^^^^^^^^^^
156
157 error: duplicate `project_replace` argument
158 --> tests/ui/pin_project/invalid.rs:139:40
159 |
160 139 | #[pin_project(project_replace = A, project_replace)] //~ ERROR duplicate `project_replace` argument
161 | ^^^^^^^^^^^^^^^
162
163 error: arguments `PinnedDrop` and `project_replace` are mutually exclusive
164 --> tests/ui/pin_project/invalid.rs:145:19
165 |
166 145 | #[pin_project(PinnedDrop, project_replace)] //~ ERROR arguments `PinnedDrop` and `project_replace` are mutually exclusive
167 | ^^^^^^^^^^
168
169 error: arguments `PinnedDrop` and `project_replace` are mutually exclusive
170 --> tests/ui/pin_project/invalid.rs:148:49
171 |
172 148 | #[pin_project(project_replace, UnsafeUnpin, PinnedDrop)] //~ ERROR arguments `PinnedDrop` and `project_replace` are mutually exclusive
173 | ^^^^^^^^^^
174
175 error: arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
176 --> tests/ui/pin_project/invalid.rs:151:19
177 |
178 151 | #[pin_project(UnsafeUnpin, !Unpin)] //~ ERROR arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
179 | ^^^^^^^^^^^
180
181 error: arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
182 --> tests/ui/pin_project/invalid.rs:154:39
183 |
184 154 | #[pin_project(!Unpin, PinnedDrop, UnsafeUnpin)] //~ ERROR arguments `UnsafeUnpin` and `!Unpin` are mutually exclusive
185 | ^^^^^^^^^^^
186
187 error: expected `!Unpin`, found `!`
188 --> tests/ui/pin_project/invalid.rs:157:19
189 |
190 157 | #[pin_project(!)] //~ ERROR expected `!Unpin`, found `!`
191 | ^
192
193 error: unexpected argument: Unpin
194 --> tests/ui/pin_project/invalid.rs:160:19
195 |
196 160 | #[pin_project(Unpin)] //~ ERROR unexpected argument
197 | ^^^^^
198
199 error: expected `project = <identifier>`, found `project`
200 --> tests/ui/pin_project/invalid.rs:163:19
201 |
202 163 | #[pin_project(project)] //~ ERROR expected `project = <identifier>`, found `project`
203 | ^^^^^^^
204
205 error: expected `project = <identifier>`, found `project =`
206 --> tests/ui/pin_project/invalid.rs:166:19
207 |
208 166 | #[pin_project(project = )] //~ ERROR expected `project = <identifier>`, found `project =`
209 | ^^^^^^^^^
210
211 error: expected identifier
212 --> tests/ui/pin_project/invalid.rs:169:29
213 |
214 169 | #[pin_project(project = !)] //~ ERROR expected identifier
215 | ^
216
217 error: expected `project_ref = <identifier>`, found `project_ref`
218 --> tests/ui/pin_project/invalid.rs:172:19
219 |
220 172 | #[pin_project(project_ref)] //~ ERROR expected `project_ref = <identifier>`, found `project_ref`
221 | ^^^^^^^^^^^
222
223 error: expected `project_ref = <identifier>`, found `project_ref =`
224 --> tests/ui/pin_project/invalid.rs:175:19
225 |
226 175 | #[pin_project(project_ref = )] //~ ERROR expected `project_ref = <identifier>`, found `project_ref =`
227 | ^^^^^^^^^^^^^
228
229 error: expected identifier
230 --> tests/ui/pin_project/invalid.rs:178:33
231 |
232 178 | #[pin_project(project_ref = !)] //~ ERROR expected identifier
233 | ^
234
235 error: expected `project_replace = <identifier>`, found `project_replace =`
236 --> tests/ui/pin_project/invalid.rs:184:19
237 |
238 184 | #[pin_project(project_replace = )] //~ ERROR expected `project_replace = <identifier>`, found `project_replace =`
239 | ^^^^^^^^^^^^^^^^^
240
241 error: expected identifier
242 --> tests/ui/pin_project/invalid.rs:187:37
243 |
244 187 | #[pin_project(project_replace = !)] //~ ERROR expected identifier
245 | ^
246
247 error: `project_replace` argument requires a value when used on enums
248 --> tests/ui/pin_project/invalid.rs:190:19
249 |
250 190 | #[pin_project(project_replace)] //~ ERROR `project_replace` argument requires a value when used on enums
251 | ^^^^^^^^^^^^^^^
252
253 error: name `OrigAndProj` is the same as the original type name
254 --> tests/ui/pin_project/invalid.rs:199:29
255 |
256 199 | #[pin_project(project = OrigAndProj)] //~ ERROR name `OrigAndProj` is the same as the original type name
257 | ^^^^^^^^^^^
258
259 error: name `OrigAndProjRef` is the same as the original type name
260 --> tests/ui/pin_project/invalid.rs:202:33
261 |
262 202 | #[pin_project(project_ref = OrigAndProjRef)] //~ ERROR name `OrigAndProjRef` is the same as the original type name
263 | ^^^^^^^^^^^^^^
264
265 error: name `OrigAndProjOwn` is the same as the original type name
266 --> tests/ui/pin_project/invalid.rs:205:37
267 |
268 205 | #[pin_project(project_replace = OrigAndProjOwn)] //~ ERROR name `OrigAndProjOwn` is the same as the original type name
269 | ^^^^^^^^^^^^^^
270
271 error: name `A` is already specified by `project` argument
272 --> tests/ui/pin_project/invalid.rs:208:46
273 |
274 208 | #[pin_project(project = A, project_ref = A)] //~ ERROR name `A` is already specified by `project` argument
275 | ^
276
277 error: name `A` is already specified by `project` argument
278 --> tests/ui/pin_project/invalid.rs:211:50
279 |
280 211 | #[pin_project(project = A, project_replace = A)] //~ ERROR name `A` is already specified by `project` argument
281 | ^
282
283 error: name `A` is already specified by `project_ref` argument
284 --> tests/ui/pin_project/invalid.rs:214:54
285 |
286 214 | #[pin_project(project_ref = A, project_replace = A)] //~ ERROR name `A` is already specified by `project_ref` argument
287 | ^
288
289 error: duplicate #[pin_project] attribute
290 --> tests/ui/pin_project/invalid.rs:222:5
291 |
292 222 | #[pin_project] //~ ERROR duplicate #[pin_project] attribute
293 | ^^^^^^^^^^^^^^
294
295 error: #[pin_project] attribute may not be used on structs with zero fields
296 --> tests/ui/pin_project/invalid.rs:230:19
297 |
298 230 | struct Struct {} //~ ERROR may not be used on structs with zero fields
299 | ^^
300
301 error: #[pin_project] attribute may not be used on structs with zero fields
302 --> tests/ui/pin_project/invalid.rs:233:23
303 |
304 233 | struct TupleStruct(); //~ ERROR may not be used on structs with zero fields
305 | ^^
306
307 error: #[pin_project] attribute may not be used on structs with zero fields
308 --> tests/ui/pin_project/invalid.rs:236:12
309 |
310 236 | struct UnitStruct; //~ ERROR may not be used on structs with zero fields
311 | ^^^^^^^^^^
312
313 error: #[pin_project] attribute may not be used on enums without variants
314 --> tests/ui/pin_project/invalid.rs:239:20
315 |
316 239 | enum EnumEmpty {} //~ ERROR may not be used on enums without variants
317 | ^^
318
319 error: #[pin_project] attribute may not be used on enums with discriminants
320 --> tests/ui/pin_project/invalid.rs:243:13
321 |
322 243 | V = 2, //~ ERROR may not be used on enums with discriminants
323 | ^
324
325 error: #[pin_project] attribute may not be used on enums with zero fields
326 --> tests/ui/pin_project/invalid.rs:248:9
327 |
328 248 | / Unit, //~ ERROR may not be used on enums with zero fields
329 249 | | Tuple(),
330 250 | | Struct {},
331 | |__________________^
332
333 error: #[pin_project] attribute may only be used on structs or enums
334 --> tests/ui/pin_project/invalid.rs:254:5
335 |
336 254 | / union Union {
337 255 | | //~^ ERROR may only be used on structs or enums
338 256 | | f: (),
339 257 | | }
340 | |_____^
341
342 error: #[pin_project] attribute may only be used on structs or enums
343 --> tests/ui/pin_project/invalid.rs:260:5
344 |
345 260 | impl Impl {} //~ ERROR may only be used on structs or enums
346 | ^^^^^^^^^^^^
347
348 error: #[pin_project] attribute may not be used on #[repr(packed)] types
349 --> tests/ui/pin_project/invalid.rs:268:12
350 |
351 268 | #[repr(packed)]
352 | ^^^^^^
353
354 error: #[pin_project] attribute may not be used on #[repr(packed)] types
355 --> tests/ui/pin_project/invalid.rs:272:12
356 |
357 272 | #[repr(packed)]
358 | ^^^^^^
359
360 error: #[pin_project] attribute may not be used on #[repr(packed)] types
361 --> tests/ui/pin_project/invalid.rs:276:12
362 |
363 276 | #[repr(packed)]
364 | ^^^^^^