1 error: requires at least a template string argument
2 --> $DIR/parse-error.rs:9:9
7 error: asm template must be a string literal
8 --> $DIR/parse-error.rs:11:14
13 error: expected token: `,`
14 --> $DIR/parse-error.rs:13:19
19 error: expected operand, clobber_abi, options, or additional template string
20 --> $DIR/parse-error.rs:15:20
23 | ^^^ expected operand, clobber_abi, options, or additional template string
25 error: expected `(`, found `foo`
26 --> $DIR/parse-error.rs:17:23
28 LL | asm!("{}", in foo);
31 error: expected `)`, found `foo`
32 --> $DIR/parse-error.rs:19:27
34 LL | asm!("{}", in(reg foo));
37 error: expected expression, found end of macro arguments
38 --> $DIR/parse-error.rs:21:27
40 LL | asm!("{}", in(reg));
41 | ^ expected expression
43 error: expected register class or explicit register
44 --> $DIR/parse-error.rs:23:26
46 LL | asm!("{}", inout(=) foo => bar);
49 error: expected expression, found end of macro arguments
50 --> $DIR/parse-error.rs:25:37
52 LL | asm!("{}", inout(reg) foo =>);
53 | ^ expected expression
55 error: expected one of `!`, `,`, `.`, `::`, `?`, `{`, or an operator, found `=>`
56 --> $DIR/parse-error.rs:27:32
58 LL | asm!("{}", in(reg) foo => bar);
59 | ^^ expected one of 7 possible tokens
61 error: argument to `sym` must be a path expression
62 --> $DIR/parse-error.rs:29:24
64 LL | asm!("{}", sym foo + bar);
67 error: expected one of `)`, `att_syntax`, `nomem`, `noreturn`, `nostack`, `preserves_flags`, `pure`, `raw`, or `readonly`, found `foo`
68 --> $DIR/parse-error.rs:31:26
70 LL | asm!("", options(foo));
71 | ^^^ expected one of 9 possible tokens
73 error: expected one of `)` or `,`, found `foo`
74 --> $DIR/parse-error.rs:33:32
76 LL | asm!("", options(nomem foo));
77 | ^^^ expected one of `)` or `,`
79 error: expected one of `)`, `att_syntax`, `nomem`, `noreturn`, `nostack`, `preserves_flags`, `pure`, `raw`, or `readonly`, found `foo`
80 --> $DIR/parse-error.rs:35:33
82 LL | asm!("", options(nomem, foo));
83 | ^^^ expected one of 9 possible tokens
85 error: arguments are not allowed after options
86 --> $DIR/parse-error.rs:37:31
88 LL | asm!("{}", options(), const foo);
89 | --------- ^^^^^^^^^ argument
93 error: expected string literal
94 --> $DIR/parse-error.rs:40:30
96 LL | asm!("", clobber_abi(foo));
97 | ^^^ not a string literal
99 error: expected `)`, found `foo`
100 --> $DIR/parse-error.rs:42:34
102 LL | asm!("", clobber_abi("C" foo));
105 error: expected `)`, found `,`
106 --> $DIR/parse-error.rs:44:33
108 LL | asm!("", clobber_abi("C", foo));
111 error: arguments are not allowed after clobber_abi
112 --> $DIR/parse-error.rs:46:38
114 LL | asm!("{}", clobber_abi("C"), const foo);
115 | ---------------- ^^^^^^^^^ argument
119 error: clobber_abi is not allowed after options
120 --> $DIR/parse-error.rs:49:29
122 LL | asm!("", options(), clobber_abi("C"));
123 | --------- ^^^^^^^^^^^^^^^^
127 error: clobber_abi is not allowed after options
128 --> $DIR/parse-error.rs:51:31
130 LL | asm!("{}", options(), clobber_abi("C"), const foo);
131 | --------- ^^^^^^^^^^^^^^^^
135 error: clobber_abi specified multiple times
136 --> $DIR/parse-error.rs:53:36
138 LL | asm!("", clobber_abi("C"), clobber_abi("C"));
139 | ---------------- ^^^^^^^^^^^^^^^^
141 | clobber_abi previously specified here
143 error: duplicate argument named `a`
144 --> $DIR/parse-error.rs:55:36
146 LL | asm!("{a}", a = const foo, a = const bar);
147 | ------------- ^^^^^^^^^^^^^ duplicate argument
151 error: argument never used
152 --> $DIR/parse-error.rs:55:36
154 LL | asm!("{a}", a = const foo, a = const bar);
155 | ^^^^^^^^^^^^^ argument never used
157 = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
159 error: explicit register arguments cannot have names
160 --> $DIR/parse-error.rs:60:18
162 LL | asm!("", a = in("x0") foo);
165 error: named arguments cannot follow explicit register arguments
166 --> $DIR/parse-error.rs:62:35
168 LL | asm!("{a}", in("x0") foo, a = const bar);
169 | ------------ ^^^^^^^^^^^^^ named argument
171 | explicit register argument
173 error: named arguments cannot follow explicit register arguments
174 --> $DIR/parse-error.rs:65:35
176 LL | asm!("{a}", in("x0") foo, a = const bar);
177 | ------------ ^^^^^^^^^^^^^ named argument
179 | explicit register argument
181 error: positional arguments cannot follow named arguments or explicit register arguments
182 --> $DIR/parse-error.rs:68:35
184 LL | asm!("{1}", in("x0") foo, const bar);
185 | ------------ ^^^^^^^^^ positional argument
187 | explicit register argument
189 error: expected one of `clobber_abi`, `const`, `in`, `inlateout`, `inout`, `lateout`, `options`, `out`, or `sym`, found `""`
190 --> $DIR/parse-error.rs:71:29
192 LL | asm!("", options(), "");
193 | ^^ expected one of 9 possible tokens
195 error: expected one of `clobber_abi`, `const`, `in`, `inlateout`, `inout`, `lateout`, `options`, `out`, or `sym`, found `"{}"`
196 --> $DIR/parse-error.rs:73:33
198 LL | asm!("{}", in(reg) foo, "{}", out(reg) foo);
199 | ^^^^ expected one of 9 possible tokens
201 error: asm template must be a string literal
202 --> $DIR/parse-error.rs:75:14
204 LL | asm!(format!("{{{}}}", 0), in(reg) foo);
205 | ^^^^^^^^^^^^^^^^^^^^
207 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
209 error: asm template must be a string literal
210 --> $DIR/parse-error.rs:77:21
212 LL | asm!("{1}", format!("{{{}}}", 0), in(reg) foo, out(reg) bar);
213 | ^^^^^^^^^^^^^^^^^^^^
215 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
217 error: _ cannot be used for input operands
218 --> $DIR/parse-error.rs:79:28
220 LL | asm!("{}", in(reg) _);
223 error: _ cannot be used for input operands
224 --> $DIR/parse-error.rs:81:31
226 LL | asm!("{}", inout(reg) _);
229 error: _ cannot be used for input operands
230 --> $DIR/parse-error.rs:83:35
232 LL | asm!("{}", inlateout(reg) _);
235 error: requires at least a template string argument
236 --> $DIR/parse-error.rs:90:1
241 error: asm template must be a string literal
242 --> $DIR/parse-error.rs:92:13
244 LL | global_asm!(FOO);
247 error: expected token: `,`
248 --> $DIR/parse-error.rs:94:18
250 LL | global_asm!("{}" FOO);
253 error: expected operand, options, or additional template string
254 --> $DIR/parse-error.rs:96:19
256 LL | global_asm!("{}", FOO);
257 | ^^^ expected operand, options, or additional template string
259 error: expected expression, found end of macro arguments
260 --> $DIR/parse-error.rs:98:24
262 LL | global_asm!("{}", const);
263 | ^ expected expression
265 error: expected one of `,`, `.`, `?`, or an operator, found `FOO`
266 --> $DIR/parse-error.rs:100:30
268 LL | global_asm!("{}", const(reg) FOO);
269 | ^^^ expected one of `,`, `.`, `?`, or an operator
271 error: expected one of `)`, `att_syntax`, or `raw`, found `FOO`
272 --> $DIR/parse-error.rs:102:25
274 LL | global_asm!("", options(FOO));
275 | ^^^ expected one of `)`, `att_syntax`, or `raw`
277 error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
278 --> $DIR/parse-error.rs:104:25
280 LL | global_asm!("", options(nomem FOO));
281 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
283 error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
284 --> $DIR/parse-error.rs:106:25
286 LL | global_asm!("", options(nomem, FOO));
287 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
289 error: arguments are not allowed after options
290 --> $DIR/parse-error.rs:108:30
292 LL | global_asm!("{}", options(), const FOO);
293 | --------- ^^^^^^^^^ argument
297 error: expected string literal
298 --> $DIR/parse-error.rs:110:29
300 LL | global_asm!("", clobber_abi(FOO));
301 | ^^^ not a string literal
303 error: expected `)`, found `FOO`
304 --> $DIR/parse-error.rs:112:33
306 LL | global_asm!("", clobber_abi("C" FOO));
309 error: expected `)`, found `,`
310 --> $DIR/parse-error.rs:114:32
312 LL | global_asm!("", clobber_abi("C", FOO));
315 error: arguments are not allowed after clobber_abi
316 --> $DIR/parse-error.rs:116:37
318 LL | global_asm!("{}", clobber_abi("C"), const FOO);
319 | ---------------- ^^^^^^^^^ argument
323 error: `clobber_abi` cannot be used with `global_asm!`
324 --> $DIR/parse-error.rs:116:19
326 LL | global_asm!("{}", clobber_abi("C"), const FOO);
329 error: clobber_abi is not allowed after options
330 --> $DIR/parse-error.rs:119:28
332 LL | global_asm!("", options(), clobber_abi("C"));
333 | --------- ^^^^^^^^^^^^^^^^
337 error: clobber_abi is not allowed after options
338 --> $DIR/parse-error.rs:121:30
340 LL | global_asm!("{}", options(), clobber_abi("C"), const FOO);
341 | --------- ^^^^^^^^^^^^^^^^
345 error: clobber_abi specified multiple times
346 --> $DIR/parse-error.rs:123:35
348 LL | global_asm!("", clobber_abi("C"), clobber_abi("C"));
349 | ---------------- ^^^^^^^^^^^^^^^^
351 | clobber_abi previously specified here
353 error: duplicate argument named `a`
354 --> $DIR/parse-error.rs:125:35
356 LL | global_asm!("{a}", a = const FOO, a = const BAR);
357 | ------------- ^^^^^^^^^^^^^ duplicate argument
361 error: argument never used
362 --> $DIR/parse-error.rs:125:35
364 LL | global_asm!("{a}", a = const FOO, a = const BAR);
365 | ^^^^^^^^^^^^^ argument never used
367 = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
369 error: expected one of `clobber_abi`, `const`, or `options`, found `""`
370 --> $DIR/parse-error.rs:128:28
372 LL | global_asm!("", options(), "");
373 | ^^ expected one of `clobber_abi`, `const`, or `options`
375 error: expected one of `clobber_abi`, `const`, or `options`, found `"{}"`
376 --> $DIR/parse-error.rs:130:30
378 LL | global_asm!("{}", const FOO, "{}", const FOO);
379 | ^^^^ expected one of `clobber_abi`, `const`, or `options`
381 error: asm template must be a string literal
382 --> $DIR/parse-error.rs:132:13
384 LL | global_asm!(format!("{{{}}}", 0), const FOO);
385 | ^^^^^^^^^^^^^^^^^^^^
387 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
389 error: asm template must be a string literal
390 --> $DIR/parse-error.rs:134:20
392 LL | global_asm!("{1}", format!("{{{}}}", 0), const FOO, const BAR);
393 | ^^^^^^^^^^^^^^^^^^^^
395 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
397 error[E0435]: attempt to use a non-constant value in a constant
398 --> $DIR/parse-error.rs:37:37
400 LL | let mut foo = 0;
401 | ---------- help: consider using `const` instead of `let`: `const foo`
403 LL | asm!("{}", options(), const foo);
404 | ^^^ non-constant value
406 error[E0435]: attempt to use a non-constant value in a constant
407 --> $DIR/parse-error.rs:46:44
409 LL | let mut foo = 0;
410 | ---------- help: consider using `const` instead of `let`: `const foo`
412 LL | asm!("{}", clobber_abi("C"), const foo);
413 | ^^^ non-constant value
415 error[E0435]: attempt to use a non-constant value in a constant
416 --> $DIR/parse-error.rs:55:31
418 LL | let mut foo = 0;
419 | ---------- help: consider using `const` instead of `let`: `const foo`
421 LL | asm!("{a}", a = const foo, a = const bar);
422 | ^^^ non-constant value
424 error[E0435]: attempt to use a non-constant value in a constant
425 --> $DIR/parse-error.rs:55:46
427 LL | let mut bar = 0;
428 | ---------- help: consider using `const` instead of `let`: `const bar`
430 LL | asm!("{a}", a = const foo, a = const bar);
431 | ^^^ non-constant value
433 error[E0435]: attempt to use a non-constant value in a constant
434 --> $DIR/parse-error.rs:62:45
436 LL | let mut bar = 0;
437 | ---------- help: consider using `const` instead of `let`: `const bar`
439 LL | asm!("{a}", in("x0") foo, a = const bar);
440 | ^^^ non-constant value
442 error[E0435]: attempt to use a non-constant value in a constant
443 --> $DIR/parse-error.rs:65:45
445 LL | let mut bar = 0;
446 | ---------- help: consider using `const` instead of `let`: `const bar`
448 LL | asm!("{a}", in("x0") foo, a = const bar);
449 | ^^^ non-constant value
451 error[E0435]: attempt to use a non-constant value in a constant
452 --> $DIR/parse-error.rs:68:41
454 LL | let mut bar = 0;
455 | ---------- help: consider using `const` instead of `let`: `const bar`
457 LL | asm!("{1}", in("x0") foo, const bar);
458 | ^^^ non-constant value
460 error: aborting due to 66 previous errors
462 For more information about this error, try `rustc --explain E0435`.