1 error: requires at least a template string argument
2 --> $DIR/parse-error.rs:11:9
7 error: asm template must be a string literal
8 --> $DIR/parse-error.rs:13:14
13 error: expected token: `,`
14 --> $DIR/parse-error.rs:15:19
19 error: expected operand, clobber_abi, options, or additional template string
20 --> $DIR/parse-error.rs:17:20
23 | ^^^ expected operand, clobber_abi, options, or additional template string
25 error: expected `(`, found `foo`
26 --> $DIR/parse-error.rs:19:23
28 LL | asm!("{}", in foo);
31 error: expected `)`, found `foo`
32 --> $DIR/parse-error.rs:21:27
34 LL | asm!("{}", in(reg foo));
37 error: expected expression, found end of macro arguments
38 --> $DIR/parse-error.rs:23:27
40 LL | asm!("{}", in(reg));
41 | ^ expected expression
43 error: expected register class or explicit register
44 --> $DIR/parse-error.rs:25:26
46 LL | asm!("{}", inout(=) foo => bar);
49 error: expected expression, found end of macro arguments
50 --> $DIR/parse-error.rs:27:37
52 LL | asm!("{}", inout(reg) foo =>);
53 | ^ expected expression
55 error: expected one of `!`, `,`, `.`, `::`, `?`, `{`, or an operator, found `=>`
56 --> $DIR/parse-error.rs:29:32
58 LL | asm!("{}", in(reg) foo => bar);
59 | ^^ expected one of 7 possible tokens
61 error: expected a path for argument to `sym`
62 --> $DIR/parse-error.rs:31:24
64 LL | asm!("{}", sym foo + bar);
67 error: expected one of `)`, `att_syntax`, `may_unwind`, `nomem`, `noreturn`, `nostack`, `preserves_flags`, `pure`, `raw`, or `readonly`, found `foo`
68 --> $DIR/parse-error.rs:33:26
70 LL | asm!("", options(foo));
71 | ^^^ expected one of 10 possible tokens
73 error: expected one of `)` or `,`, found `foo`
74 --> $DIR/parse-error.rs:35:32
76 LL | asm!("", options(nomem foo));
77 | ^^^ expected one of `)` or `,`
79 error: expected one of `)`, `att_syntax`, `may_unwind`, `nomem`, `noreturn`, `nostack`, `preserves_flags`, `pure`, `raw`, or `readonly`, found `foo`
80 --> $DIR/parse-error.rs:37:33
82 LL | asm!("", options(nomem, foo));
83 | ^^^ expected one of 10 possible tokens
85 error: arguments are not allowed after options
86 --> $DIR/parse-error.rs:39:31
88 LL | asm!("{}", options(), const foo);
89 | --------- ^^^^^^^^^ argument
93 error: at least one abi must be provided as an argument to `clobber_abi`
94 --> $DIR/parse-error.rs:42:30
96 LL | asm!("", clobber_abi());
99 error: expected string literal
100 --> $DIR/parse-error.rs:44:30
102 LL | asm!("", clobber_abi(foo));
103 | ^^^ not a string literal
105 error: expected one of `)` or `,`, found `foo`
106 --> $DIR/parse-error.rs:46:34
108 LL | asm!("", clobber_abi("C" foo));
109 | ^^^ expected one of `)` or `,`
111 error: expected string literal
112 --> $DIR/parse-error.rs:48:35
114 LL | asm!("", clobber_abi("C", foo));
115 | ^^^ not a string literal
117 error: arguments are not allowed after clobber_abi
118 --> $DIR/parse-error.rs:50:38
120 LL | asm!("{}", clobber_abi("C"), const foo);
121 | ---------------- ^^^^^^^^^ argument
125 error: clobber_abi is not allowed after options
126 --> $DIR/parse-error.rs:53:29
128 LL | asm!("", options(), clobber_abi("C"));
129 | --------- ^^^^^^^^^^^^^^^^
133 error: clobber_abi is not allowed after options
134 --> $DIR/parse-error.rs:55:31
136 LL | asm!("{}", options(), clobber_abi("C"), const foo);
137 | --------- ^^^^^^^^^^^^^^^^
141 error: duplicate argument named `a`
142 --> $DIR/parse-error.rs:57:36
144 LL | asm!("{a}", a = const foo, a = const bar);
145 | ------------- ^^^^^^^^^^^^^ duplicate argument
149 error: argument never used
150 --> $DIR/parse-error.rs:57:36
152 LL | asm!("{a}", a = const foo, a = const bar);
153 | ^^^^^^^^^^^^^ argument never used
155 = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
157 error: explicit register arguments cannot have names
158 --> $DIR/parse-error.rs:62:18
160 LL | asm!("", a = in("eax") foo);
163 error: named arguments cannot follow explicit register arguments
164 --> $DIR/parse-error.rs:64:36
166 LL | asm!("{a}", in("eax") foo, a = const bar);
167 | ------------- ^^^^^^^^^^^^^ named argument
169 | explicit register argument
171 error: named arguments cannot follow explicit register arguments
172 --> $DIR/parse-error.rs:67:36
174 LL | asm!("{a}", in("eax") foo, a = const bar);
175 | ------------- ^^^^^^^^^^^^^ named argument
177 | explicit register argument
179 error: positional arguments cannot follow named arguments or explicit register arguments
180 --> $DIR/parse-error.rs:70:36
182 LL | asm!("{1}", in("eax") foo, const bar);
183 | ------------- ^^^^^^^^^ positional argument
185 | explicit register argument
187 error: expected one of `clobber_abi`, `const`, `in`, `inlateout`, `inout`, `lateout`, `options`, `out`, or `sym`, found `""`
188 --> $DIR/parse-error.rs:73:29
190 LL | asm!("", options(), "");
191 | ^^ expected one of 9 possible tokens
193 error: expected one of `clobber_abi`, `const`, `in`, `inlateout`, `inout`, `lateout`, `options`, `out`, or `sym`, found `"{}"`
194 --> $DIR/parse-error.rs:75:33
196 LL | asm!("{}", in(reg) foo, "{}", out(reg) foo);
197 | ^^^^ expected one of 9 possible tokens
199 error: asm template must be a string literal
200 --> $DIR/parse-error.rs:77:14
202 LL | asm!(format!("{{{}}}", 0), in(reg) foo);
203 | ^^^^^^^^^^^^^^^^^^^^
205 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
207 error: asm template must be a string literal
208 --> $DIR/parse-error.rs:79:21
210 LL | asm!("{1}", format!("{{{}}}", 0), in(reg) foo, out(reg) bar);
211 | ^^^^^^^^^^^^^^^^^^^^
213 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
215 error: _ cannot be used for input operands
216 --> $DIR/parse-error.rs:81:28
218 LL | asm!("{}", in(reg) _);
221 error: _ cannot be used for input operands
222 --> $DIR/parse-error.rs:83:31
224 LL | asm!("{}", inout(reg) _);
227 error: _ cannot be used for input operands
228 --> $DIR/parse-error.rs:85:35
230 LL | asm!("{}", inlateout(reg) _);
233 error: requires at least a template string argument
234 --> $DIR/parse-error.rs:92:1
239 error: asm template must be a string literal
240 --> $DIR/parse-error.rs:94:13
242 LL | global_asm!(FOO);
245 error: expected token: `,`
246 --> $DIR/parse-error.rs:96:18
248 LL | global_asm!("{}" FOO);
251 error: expected operand, options, or additional template string
252 --> $DIR/parse-error.rs:98:19
254 LL | global_asm!("{}", FOO);
255 | ^^^ expected operand, options, or additional template string
257 error: expected expression, found end of macro arguments
258 --> $DIR/parse-error.rs:100:24
260 LL | global_asm!("{}", const);
261 | ^ expected expression
263 error: expected one of `,`, `.`, `?`, or an operator, found `FOO`
264 --> $DIR/parse-error.rs:102:30
266 LL | global_asm!("{}", const(reg) FOO);
267 | ^^^ expected one of `,`, `.`, `?`, or an operator
269 error: expected one of `)`, `att_syntax`, or `raw`, found `FOO`
270 --> $DIR/parse-error.rs:104:25
272 LL | global_asm!("", options(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:106:25
278 LL | global_asm!("", options(nomem FOO));
279 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
281 error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
282 --> $DIR/parse-error.rs:108:25
284 LL | global_asm!("", options(nomem, FOO));
285 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
287 error: arguments are not allowed after options
288 --> $DIR/parse-error.rs:110:30
290 LL | global_asm!("{}", options(), const FOO);
291 | --------- ^^^^^^^^^ argument
295 error: expected string literal
296 --> $DIR/parse-error.rs:112:29
298 LL | global_asm!("", clobber_abi(FOO));
299 | ^^^ not a string literal
301 error: expected one of `)` or `,`, found `FOO`
302 --> $DIR/parse-error.rs:114:33
304 LL | global_asm!("", clobber_abi("C" FOO));
305 | ^^^ expected one of `)` or `,`
307 error: expected string literal
308 --> $DIR/parse-error.rs:116:34
310 LL | global_asm!("", clobber_abi("C", FOO));
311 | ^^^ not a string literal
313 error: arguments are not allowed after clobber_abi
314 --> $DIR/parse-error.rs:118:37
316 LL | global_asm!("{}", clobber_abi("C"), const FOO);
317 | ---------------- ^^^^^^^^^ argument
321 error: `clobber_abi` cannot be used with `global_asm!`
322 --> $DIR/parse-error.rs:118:19
324 LL | global_asm!("{}", clobber_abi("C"), const FOO);
327 error: clobber_abi is not allowed after options
328 --> $DIR/parse-error.rs:121:28
330 LL | global_asm!("", options(), clobber_abi("C"));
331 | --------- ^^^^^^^^^^^^^^^^
335 error: clobber_abi is not allowed after options
336 --> $DIR/parse-error.rs:123:30
338 LL | global_asm!("{}", options(), clobber_abi("C"), const FOO);
339 | --------- ^^^^^^^^^^^^^^^^
343 error: `clobber_abi` cannot be used with `global_asm!`
344 --> $DIR/parse-error.rs:125:17
346 LL | global_asm!("", clobber_abi("C"), clobber_abi("C"));
347 | ^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^
349 error: duplicate argument named `a`
350 --> $DIR/parse-error.rs:127:35
352 LL | global_asm!("{a}", a = const FOO, a = const BAR);
353 | ------------- ^^^^^^^^^^^^^ duplicate argument
357 error: argument never used
358 --> $DIR/parse-error.rs:127:35
360 LL | global_asm!("{a}", a = const FOO, a = const BAR);
361 | ^^^^^^^^^^^^^ argument never used
363 = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
365 error: expected one of `clobber_abi`, `const`, `options`, or `sym`, found `""`
366 --> $DIR/parse-error.rs:130:28
368 LL | global_asm!("", options(), "");
369 | ^^ expected one of `clobber_abi`, `const`, `options`, or `sym`
371 error: expected one of `clobber_abi`, `const`, `options`, or `sym`, found `"{}"`
372 --> $DIR/parse-error.rs:132:30
374 LL | global_asm!("{}", const FOO, "{}", const FOO);
375 | ^^^^ expected one of `clobber_abi`, `const`, `options`, or `sym`
377 error: asm template must be a string literal
378 --> $DIR/parse-error.rs:134:13
380 LL | global_asm!(format!("{{{}}}", 0), const FOO);
381 | ^^^^^^^^^^^^^^^^^^^^
383 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
385 error: asm template must be a string literal
386 --> $DIR/parse-error.rs:136:20
388 LL | global_asm!("{1}", format!("{{{}}}", 0), const FOO, const BAR);
389 | ^^^^^^^^^^^^^^^^^^^^
391 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
393 error[E0435]: attempt to use a non-constant value in a constant
394 --> $DIR/parse-error.rs:39:37
396 LL | let mut foo = 0;
397 | ----------- help: consider using `const` instead of `let`: `const foo`
399 LL | asm!("{}", options(), const foo);
400 | ^^^ non-constant value
402 error[E0435]: attempt to use a non-constant value in a constant
403 --> $DIR/parse-error.rs:50:44
405 LL | let mut foo = 0;
406 | ----------- help: consider using `const` instead of `let`: `const foo`
408 LL | asm!("{}", clobber_abi("C"), const foo);
409 | ^^^ non-constant value
411 error[E0435]: attempt to use a non-constant value in a constant
412 --> $DIR/parse-error.rs:57:31
414 LL | let mut foo = 0;
415 | ----------- help: consider using `const` instead of `let`: `const foo`
417 LL | asm!("{a}", a = const foo, a = const bar);
418 | ^^^ non-constant value
420 error[E0435]: attempt to use a non-constant value in a constant
421 --> $DIR/parse-error.rs:57:46
423 LL | let mut bar = 0;
424 | ----------- help: consider using `const` instead of `let`: `const bar`
426 LL | asm!("{a}", a = const foo, a = const bar);
427 | ^^^ non-constant value
429 error[E0435]: attempt to use a non-constant value in a constant
430 --> $DIR/parse-error.rs:64:46
432 LL | let mut bar = 0;
433 | ----------- help: consider using `const` instead of `let`: `const bar`
435 LL | asm!("{a}", in("eax") foo, a = const bar);
436 | ^^^ non-constant value
438 error[E0435]: attempt to use a non-constant value in a constant
439 --> $DIR/parse-error.rs:67:46
441 LL | let mut bar = 0;
442 | ----------- help: consider using `const` instead of `let`: `const bar`
444 LL | asm!("{a}", in("eax") foo, a = const bar);
445 | ^^^ non-constant value
447 error[E0435]: attempt to use a non-constant value in a constant
448 --> $DIR/parse-error.rs:70:42
450 LL | let mut bar = 0;
451 | ----------- help: consider using `const` instead of `let`: `const bar`
453 LL | asm!("{1}", in("eax") foo, const bar);
454 | ^^^ non-constant value
456 error: aborting due to 66 previous errors
458 For more information about this error, try `rustc --explain E0435`.