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 one of `)` or `,`, found `foo`
100 --> $DIR/parse-error.rs:42:34
102 LL | asm!("", clobber_abi("C" foo));
103 | ^^^ expected one of `)` or `,`
105 error: expected string literal
106 --> $DIR/parse-error.rs:44:35
108 LL | asm!("", clobber_abi("C", foo));
109 | ^^^ not a string literal
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: duplicate argument named `a`
136 --> $DIR/parse-error.rs:53:36
138 LL | asm!("{a}", a = const foo, a = const bar);
139 | ------------- ^^^^^^^^^^^^^ duplicate argument
143 error: argument never used
144 --> $DIR/parse-error.rs:53:36
146 LL | asm!("{a}", a = const foo, a = const bar);
147 | ^^^^^^^^^^^^^ argument never used
149 = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
151 error: explicit register arguments cannot have names
152 --> $DIR/parse-error.rs:58:18
154 LL | asm!("", a = in("x0") foo);
157 error: named arguments cannot follow explicit register arguments
158 --> $DIR/parse-error.rs:60:35
160 LL | asm!("{a}", in("x0") foo, a = const bar);
161 | ------------ ^^^^^^^^^^^^^ named argument
163 | explicit register argument
165 error: named arguments cannot follow explicit register arguments
166 --> $DIR/parse-error.rs:63:35
168 LL | asm!("{a}", in("x0") foo, a = const bar);
169 | ------------ ^^^^^^^^^^^^^ named argument
171 | explicit register argument
173 error: positional arguments cannot follow named arguments or explicit register arguments
174 --> $DIR/parse-error.rs:66:35
176 LL | asm!("{1}", in("x0") foo, const bar);
177 | ------------ ^^^^^^^^^ positional argument
179 | explicit register argument
181 error: expected one of `clobber_abi`, `const`, `in`, `inlateout`, `inout`, `lateout`, `options`, `out`, or `sym`, found `""`
182 --> $DIR/parse-error.rs:69:29
184 LL | asm!("", options(), "");
185 | ^^ expected one of 9 possible tokens
187 error: expected one of `clobber_abi`, `const`, `in`, `inlateout`, `inout`, `lateout`, `options`, `out`, or `sym`, found `"{}"`
188 --> $DIR/parse-error.rs:71:33
190 LL | asm!("{}", in(reg) foo, "{}", out(reg) foo);
191 | ^^^^ expected one of 9 possible tokens
193 error: asm template must be a string literal
194 --> $DIR/parse-error.rs:73:14
196 LL | asm!(format!("{{{}}}", 0), in(reg) foo);
197 | ^^^^^^^^^^^^^^^^^^^^
199 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
201 error: asm template must be a string literal
202 --> $DIR/parse-error.rs:75:21
204 LL | asm!("{1}", format!("{{{}}}", 0), in(reg) foo, out(reg) bar);
205 | ^^^^^^^^^^^^^^^^^^^^
207 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
209 error: _ cannot be used for input operands
210 --> $DIR/parse-error.rs:77:28
212 LL | asm!("{}", in(reg) _);
215 error: _ cannot be used for input operands
216 --> $DIR/parse-error.rs:79:31
218 LL | asm!("{}", inout(reg) _);
221 error: _ cannot be used for input operands
222 --> $DIR/parse-error.rs:81:35
224 LL | asm!("{}", inlateout(reg) _);
227 error: requires at least a template string argument
228 --> $DIR/parse-error.rs:88:1
233 error: asm template must be a string literal
234 --> $DIR/parse-error.rs:90:13
236 LL | global_asm!(FOO);
239 error: expected token: `,`
240 --> $DIR/parse-error.rs:92:18
242 LL | global_asm!("{}" FOO);
245 error: expected operand, options, or additional template string
246 --> $DIR/parse-error.rs:94:19
248 LL | global_asm!("{}", FOO);
249 | ^^^ expected operand, options, or additional template string
251 error: expected expression, found end of macro arguments
252 --> $DIR/parse-error.rs:96:24
254 LL | global_asm!("{}", const);
255 | ^ expected expression
257 error: expected one of `,`, `.`, `?`, or an operator, found `FOO`
258 --> $DIR/parse-error.rs:98:30
260 LL | global_asm!("{}", const(reg) FOO);
261 | ^^^ expected one of `,`, `.`, `?`, or an operator
263 error: expected one of `)`, `att_syntax`, or `raw`, found `FOO`
264 --> $DIR/parse-error.rs:100:25
266 LL | global_asm!("", options(FOO));
267 | ^^^ expected one of `)`, `att_syntax`, or `raw`
269 error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
270 --> $DIR/parse-error.rs:102:25
272 LL | global_asm!("", options(nomem FOO));
273 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
275 error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
276 --> $DIR/parse-error.rs:104:25
278 LL | global_asm!("", options(nomem, FOO));
279 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
281 error: arguments are not allowed after options
282 --> $DIR/parse-error.rs:106:30
284 LL | global_asm!("{}", options(), const FOO);
285 | --------- ^^^^^^^^^ argument
289 error: expected string literal
290 --> $DIR/parse-error.rs:108:29
292 LL | global_asm!("", clobber_abi(FOO));
293 | ^^^ not a string literal
295 error: expected one of `)` or `,`, found `FOO`
296 --> $DIR/parse-error.rs:110:33
298 LL | global_asm!("", clobber_abi("C" FOO));
299 | ^^^ expected one of `)` or `,`
301 error: expected string literal
302 --> $DIR/parse-error.rs:112:34
304 LL | global_asm!("", clobber_abi("C", FOO));
305 | ^^^ not a string literal
307 error: arguments are not allowed after clobber_abi
308 --> $DIR/parse-error.rs:114:37
310 LL | global_asm!("{}", clobber_abi("C"), const FOO);
311 | ---------------- ^^^^^^^^^ argument
315 error: `clobber_abi` cannot be used with `global_asm!`
316 --> $DIR/parse-error.rs:114:19
318 LL | global_asm!("{}", clobber_abi("C"), const FOO);
321 error: clobber_abi is not allowed after options
322 --> $DIR/parse-error.rs:117:28
324 LL | global_asm!("", options(), clobber_abi("C"));
325 | --------- ^^^^^^^^^^^^^^^^
329 error: clobber_abi is not allowed after options
330 --> $DIR/parse-error.rs:119:30
332 LL | global_asm!("{}", options(), clobber_abi("C"), const FOO);
333 | --------- ^^^^^^^^^^^^^^^^
337 error: duplicate argument named `a`
338 --> $DIR/parse-error.rs:121:35
340 LL | global_asm!("{a}", a = const FOO, a = const BAR);
341 | ------------- ^^^^^^^^^^^^^ duplicate argument
345 error: argument never used
346 --> $DIR/parse-error.rs:121:35
348 LL | global_asm!("{a}", a = const FOO, a = const BAR);
349 | ^^^^^^^^^^^^^ argument never used
351 = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
353 error: expected one of `clobber_abi`, `const`, or `options`, found `""`
354 --> $DIR/parse-error.rs:124:28
356 LL | global_asm!("", options(), "");
357 | ^^ expected one of `clobber_abi`, `const`, or `options`
359 error: expected one of `clobber_abi`, `const`, or `options`, found `"{}"`
360 --> $DIR/parse-error.rs:126:30
362 LL | global_asm!("{}", const FOO, "{}", const FOO);
363 | ^^^^ expected one of `clobber_abi`, `const`, or `options`
365 error: asm template must be a string literal
366 --> $DIR/parse-error.rs:128:13
368 LL | global_asm!(format!("{{{}}}", 0), const FOO);
369 | ^^^^^^^^^^^^^^^^^^^^
371 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
373 error: asm template must be a string literal
374 --> $DIR/parse-error.rs:130:20
376 LL | global_asm!("{1}", format!("{{{}}}", 0), const FOO, const BAR);
377 | ^^^^^^^^^^^^^^^^^^^^
379 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
381 error[E0435]: attempt to use a non-constant value in a constant
382 --> $DIR/parse-error.rs:37:37
384 LL | let mut foo = 0;
385 | ---------- help: consider using `const` instead of `let`: `const foo`
387 LL | asm!("{}", options(), const foo);
388 | ^^^ non-constant value
390 error[E0435]: attempt to use a non-constant value in a constant
391 --> $DIR/parse-error.rs:46:44
393 LL | let mut foo = 0;
394 | ---------- help: consider using `const` instead of `let`: `const foo`
396 LL | asm!("{}", clobber_abi("C"), const foo);
397 | ^^^ non-constant value
399 error[E0435]: attempt to use a non-constant value in a constant
400 --> $DIR/parse-error.rs:53:31
402 LL | let mut foo = 0;
403 | ---------- help: consider using `const` instead of `let`: `const foo`
405 LL | asm!("{a}", a = const foo, a = const bar);
406 | ^^^ non-constant value
408 error[E0435]: attempt to use a non-constant value in a constant
409 --> $DIR/parse-error.rs:53:46
411 LL | let mut bar = 0;
412 | ---------- help: consider using `const` instead of `let`: `const bar`
414 LL | asm!("{a}", a = const foo, a = const bar);
415 | ^^^ non-constant value
417 error[E0435]: attempt to use a non-constant value in a constant
418 --> $DIR/parse-error.rs:60:45
420 LL | let mut bar = 0;
421 | ---------- help: consider using `const` instead of `let`: `const bar`
423 LL | asm!("{a}", in("x0") foo, a = const bar);
424 | ^^^ non-constant value
426 error[E0435]: attempt to use a non-constant value in a constant
427 --> $DIR/parse-error.rs:63:45
429 LL | let mut bar = 0;
430 | ---------- help: consider using `const` instead of `let`: `const bar`
432 LL | asm!("{a}", in("x0") foo, a = const bar);
433 | ^^^ non-constant value
435 error[E0435]: attempt to use a non-constant value in a constant
436 --> $DIR/parse-error.rs:66:41
438 LL | let mut bar = 0;
439 | ---------- help: consider using `const` instead of `let`: `const bar`
441 LL | asm!("{1}", in("x0") foo, const bar);
442 | ^^^ non-constant value
444 error: aborting due to 64 previous errors
446 For more information about this error, try `rustc --explain E0435`.