@@ -214,162 +214,180 @@ LL | asm!("{1}", format!("{{{}}}", 0), in(reg) foo, out(reg) bar);
214
214
|
215
215
= note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
216
216
217
+ error: _ cannot be used for input operands
218
+ --> $DIR/parse-error.rs:79:28
219
+ |
220
+ LL | asm!("{}", in(reg) _);
221
+ | ^
222
+
223
+ error: _ cannot be used for input operands
224
+ --> $DIR/parse-error.rs:81:31
225
+ |
226
+ LL | asm!("{}", inout(reg) _);
227
+ | ^
228
+
229
+ error: _ cannot be used for input operands
230
+ --> $DIR/parse-error.rs:83:35
231
+ |
232
+ LL | asm!("{}", inlateout(reg) _);
233
+ | ^
234
+
217
235
error: requires at least a template string argument
218
- --> $DIR/parse-error.rs:84 :1
236
+ --> $DIR/parse-error.rs:90 :1
219
237
|
220
238
LL | global_asm!();
221
239
| ^^^^^^^^^^^^^^
222
240
223
241
error: asm template must be a string literal
224
- --> $DIR/parse-error.rs:86 :13
242
+ --> $DIR/parse-error.rs:92 :13
225
243
|
226
244
LL | global_asm!(FOO);
227
245
| ^^^
228
246
229
247
error: expected token: `,`
230
- --> $DIR/parse-error.rs:88 :18
248
+ --> $DIR/parse-error.rs:94 :18
231
249
|
232
250
LL | global_asm!("{}" FOO);
233
251
| ^^^ expected `,`
234
252
235
253
error: expected operand, options, or additional template string
236
- --> $DIR/parse-error.rs:90 :19
254
+ --> $DIR/parse-error.rs:96 :19
237
255
|
238
256
LL | global_asm!("{}", FOO);
239
257
| ^^^ expected operand, options, or additional template string
240
258
241
259
error: expected expression, found end of macro arguments
242
- --> $DIR/parse-error.rs:92 :24
260
+ --> $DIR/parse-error.rs:98 :24
243
261
|
244
262
LL | global_asm!("{}", const);
245
263
| ^ expected expression
246
264
247
265
error: expected one of `,`, `.`, `?`, or an operator, found `FOO`
248
- --> $DIR/parse-error.rs:94 :30
266
+ --> $DIR/parse-error.rs:100 :30
249
267
|
250
268
LL | global_asm!("{}", const(reg) FOO);
251
269
| ^^^ expected one of `,`, `.`, `?`, or an operator
252
270
253
271
error: expected one of `)`, `att_syntax`, or `raw`, found `FOO`
254
- --> $DIR/parse-error.rs:96 :25
272
+ --> $DIR/parse-error.rs:102 :25
255
273
|
256
274
LL | global_asm!("", options(FOO));
257
275
| ^^^ expected one of `)`, `att_syntax`, or `raw`
258
276
259
277
error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
260
- --> $DIR/parse-error.rs:98 :25
278
+ --> $DIR/parse-error.rs:104 :25
261
279
|
262
280
LL | global_asm!("", options(nomem FOO));
263
281
| ^^^^^ expected one of `)`, `att_syntax`, or `raw`
264
282
265
283
error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
266
- --> $DIR/parse-error.rs:100 :25
284
+ --> $DIR/parse-error.rs:106 :25
267
285
|
268
286
LL | global_asm!("", options(nomem, FOO));
269
287
| ^^^^^ expected one of `)`, `att_syntax`, or `raw`
270
288
271
289
error: arguments are not allowed after options
272
- --> $DIR/parse-error.rs:102 :30
290
+ --> $DIR/parse-error.rs:108 :30
273
291
|
274
292
LL | global_asm!("{}", options(), const FOO);
275
293
| --------- ^^^^^^^^^ argument
276
294
| |
277
295
| previous options
278
296
279
297
error: expected string literal
280
- --> $DIR/parse-error.rs:104 :29
298
+ --> $DIR/parse-error.rs:110 :29
281
299
|
282
300
LL | global_asm!("", clobber_abi(FOO));
283
301
| ^^^ not a string literal
284
302
285
303
error: expected `)`, found `FOO`
286
- --> $DIR/parse-error.rs:106 :33
304
+ --> $DIR/parse-error.rs:112 :33
287
305
|
288
306
LL | global_asm!("", clobber_abi("C" FOO));
289
307
| ^^^ expected `)`
290
308
291
309
error: expected `)`, found `,`
292
- --> $DIR/parse-error.rs:108 :32
310
+ --> $DIR/parse-error.rs:114 :32
293
311
|
294
312
LL | global_asm!("", clobber_abi("C", FOO));
295
313
| ^ expected `)`
296
314
297
315
error: arguments are not allowed after clobber_abi
298
- --> $DIR/parse-error.rs:110 :37
316
+ --> $DIR/parse-error.rs:116 :37
299
317
|
300
318
LL | global_asm!("{}", clobber_abi("C"), const FOO);
301
319
| ---------------- ^^^^^^^^^ argument
302
320
| |
303
321
| clobber_abi
304
322
305
323
error: `clobber_abi` cannot be used with `global_asm!`
306
- --> $DIR/parse-error.rs:110 :19
324
+ --> $DIR/parse-error.rs:116 :19
307
325
|
308
326
LL | global_asm!("{}", clobber_abi("C"), const FOO);
309
327
| ^^^^^^^^^^^^^^^^
310
328
311
329
error: clobber_abi is not allowed after options
312
- --> $DIR/parse-error.rs:113 :28
330
+ --> $DIR/parse-error.rs:119 :28
313
331
|
314
332
LL | global_asm!("", options(), clobber_abi("C"));
315
333
| --------- ^^^^^^^^^^^^^^^^
316
334
| |
317
335
| options
318
336
319
337
error: clobber_abi is not allowed after options
320
- --> $DIR/parse-error.rs:115 :30
338
+ --> $DIR/parse-error.rs:121 :30
321
339
|
322
340
LL | global_asm!("{}", options(), clobber_abi("C"), const FOO);
323
341
| --------- ^^^^^^^^^^^^^^^^
324
342
| |
325
343
| options
326
344
327
345
error: clobber_abi specified multiple times
328
- --> $DIR/parse-error.rs:117 :35
346
+ --> $DIR/parse-error.rs:123 :35
329
347
|
330
348
LL | global_asm!("", clobber_abi("C"), clobber_abi("C"));
331
349
| ---------------- ^^^^^^^^^^^^^^^^
332
350
| |
333
351
| clobber_abi previously specified here
334
352
335
353
error: duplicate argument named `a`
336
- --> $DIR/parse-error.rs:119 :35
354
+ --> $DIR/parse-error.rs:125 :35
337
355
|
338
356
LL | global_asm!("{a}", a = const FOO, a = const BAR);
339
357
| ------------- ^^^^^^^^^^^^^ duplicate argument
340
358
| |
341
359
| previously here
342
360
343
361
error: argument never used
344
- --> $DIR/parse-error.rs:119 :35
362
+ --> $DIR/parse-error.rs:125 :35
345
363
|
346
364
LL | global_asm!("{a}", a = const FOO, a = const BAR);
347
365
| ^^^^^^^^^^^^^ argument never used
348
366
|
349
367
= help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
350
368
351
369
error: expected one of `clobber_abi`, `const`, or `options`, found `""`
352
- --> $DIR/parse-error.rs:122 :28
370
+ --> $DIR/parse-error.rs:128 :28
353
371
|
354
372
LL | global_asm!("", options(), "");
355
373
| ^^ expected one of `clobber_abi`, `const`, or `options`
356
374
357
375
error: expected one of `clobber_abi`, `const`, or `options`, found `"{}"`
358
- --> $DIR/parse-error.rs:124 :30
376
+ --> $DIR/parse-error.rs:130 :30
359
377
|
360
378
LL | global_asm!("{}", const FOO, "{}", const FOO);
361
379
| ^^^^ expected one of `clobber_abi`, `const`, or `options`
362
380
363
381
error: asm template must be a string literal
364
- --> $DIR/parse-error.rs:126 :13
382
+ --> $DIR/parse-error.rs:132 :13
365
383
|
366
384
LL | global_asm!(format!("{{{}}}", 0), const FOO);
367
385
| ^^^^^^^^^^^^^^^^^^^^
368
386
|
369
387
= note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
370
388
371
389
error: asm template must be a string literal
372
- --> $DIR/parse-error.rs:128 :20
390
+ --> $DIR/parse-error.rs:134 :20
373
391
|
374
392
LL | global_asm!("{1}", format!("{{{}}}", 0), const FOO, const BAR);
375
393
| ^^^^^^^^^^^^^^^^^^^^
@@ -439,6 +457,6 @@ LL | let mut bar = 0;
439
457
LL | asm!("{1}", in("x0") foo, const bar);
440
458
| ^^^ non-constant value
441
459
442
- error: aborting due to 63 previous errors
460
+ error: aborting due to 66 previous errors
443
461
444
462
For more information about this error, try `rustc --explain E0435`.
0 commit comments