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("eax") foo);
165 error: named arguments cannot follow explicit register arguments
166 --> $DIR/parse-error.rs:62:36
168 LL | asm!("{a}", in("eax") 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:36
176 LL | asm!("{a}", in("eax") 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:36
184 LL | asm!("{1}", in("eax") 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: requires at least a template string argument
218 --> $DIR/parse-error.rs:84:1
223 error: asm template must be a string literal
224 --> $DIR/parse-error.rs:86:13
226 LL | global_asm!(FOO);
229 error: expected token: `,`
230 --> $DIR/parse-error.rs:88:18
232 LL | global_asm!("{}" FOO);
235 error: expected operand, options, or additional template string
236 --> $DIR/parse-error.rs:90:19
238 LL | global_asm!("{}", FOO);
239 | ^^^ expected operand, options, or additional template string
241 error: expected expression, found end of macro arguments
242 --> $DIR/parse-error.rs:92:24
244 LL | global_asm!("{}", const);
245 | ^ expected expression
247 error: expected one of `,`, `.`, `?`, or an operator, found `FOO`
248 --> $DIR/parse-error.rs:94:30
250 LL | global_asm!("{}", const(reg) FOO);
251 | ^^^ expected one of `,`, `.`, `?`, or an operator
253 error: expected one of `)`, `att_syntax`, or `raw`, found `FOO`
254 --> $DIR/parse-error.rs:96:25
256 LL | global_asm!("", options(FOO));
257 | ^^^ expected one of `)`, `att_syntax`, or `raw`
259 error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
260 --> $DIR/parse-error.rs:98:25
262 LL | global_asm!("", options(nomem FOO));
263 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
265 error: expected one of `)`, `att_syntax`, or `raw`, found `nomem`
266 --> $DIR/parse-error.rs:100:25
268 LL | global_asm!("", options(nomem, FOO));
269 | ^^^^^ expected one of `)`, `att_syntax`, or `raw`
271 error: arguments are not allowed after options
272 --> $DIR/parse-error.rs:102:30
274 LL | global_asm!("{}", options(), const FOO);
275 | --------- ^^^^^^^^^ argument
279 error: expected string literal
280 --> $DIR/parse-error.rs:104:29
282 LL | global_asm!("", clobber_abi(FOO));
283 | ^^^ not a string literal
285 error: expected `)`, found `FOO`
286 --> $DIR/parse-error.rs:106:33
288 LL | global_asm!("", clobber_abi("C" FOO));
291 error: expected `)`, found `,`
292 --> $DIR/parse-error.rs:108:32
294 LL | global_asm!("", clobber_abi("C", FOO));
297 error: arguments are not allowed after clobber_abi
298 --> $DIR/parse-error.rs:110:37
300 LL | global_asm!("{}", clobber_abi("C"), const FOO);
301 | ---------------- ^^^^^^^^^ argument
305 error: `clobber_abi` cannot be used with `global_asm!`
306 --> $DIR/parse-error.rs:110:19
308 LL | global_asm!("{}", clobber_abi("C"), const FOO);
311 error: clobber_abi is not allowed after options
312 --> $DIR/parse-error.rs:113:28
314 LL | global_asm!("", options(), clobber_abi("C"));
315 | --------- ^^^^^^^^^^^^^^^^
319 error: clobber_abi is not allowed after options
320 --> $DIR/parse-error.rs:115:30
322 LL | global_asm!("{}", options(), clobber_abi("C"), const FOO);
323 | --------- ^^^^^^^^^^^^^^^^
327 error: clobber_abi specified multiple times
328 --> $DIR/parse-error.rs:117:35
330 LL | global_asm!("", clobber_abi("C"), clobber_abi("C"));
331 | ---------------- ^^^^^^^^^^^^^^^^
333 | clobber_abi previously specified here
335 error: duplicate argument named `a`
336 --> $DIR/parse-error.rs:119:35
338 LL | global_asm!("{a}", a = const FOO, a = const BAR);
339 | ------------- ^^^^^^^^^^^^^ duplicate argument
343 error: argument never used
344 --> $DIR/parse-error.rs:119:35
346 LL | global_asm!("{a}", a = const FOO, a = const BAR);
347 | ^^^^^^^^^^^^^ argument never used
349 = help: if this argument is intentionally unused, consider using it in an asm comment: `"/* {1} */"`
351 error: expected one of `clobber_abi`, `const`, or `options`, found `""`
352 --> $DIR/parse-error.rs:122:28
354 LL | global_asm!("", options(), "");
355 | ^^ expected one of `clobber_abi`, `const`, or `options`
357 error: expected one of `clobber_abi`, `const`, or `options`, found `"{}"`
358 --> $DIR/parse-error.rs:124:30
360 LL | global_asm!("{}", const FOO, "{}", const FOO);
361 | ^^^^ expected one of `clobber_abi`, `const`, or `options`
363 error: asm template must be a string literal
364 --> $DIR/parse-error.rs:126:13
366 LL | global_asm!(format!("{{{}}}", 0), const FOO);
367 | ^^^^^^^^^^^^^^^^^^^^
369 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
371 error: asm template must be a string literal
372 --> $DIR/parse-error.rs:128:20
374 LL | global_asm!("{1}", format!("{{{}}}", 0), const FOO, const BAR);
375 | ^^^^^^^^^^^^^^^^^^^^
377 = note: this error originates in the macro `format` (in Nightly builds, run with -Z macro-backtrace for more info)
379 error[E0435]: attempt to use a non-constant value in a constant
380 --> $DIR/parse-error.rs:37:37
382 LL | let mut foo = 0;
383 | ---------- help: consider using `const` instead of `let`: `const foo`
385 LL | asm!("{}", options(), const foo);
386 | ^^^ non-constant value
388 error[E0435]: attempt to use a non-constant value in a constant
389 --> $DIR/parse-error.rs:46:44
391 LL | let mut foo = 0;
392 | ---------- help: consider using `const` instead of `let`: `const foo`
394 LL | asm!("{}", clobber_abi("C"), const foo);
395 | ^^^ non-constant value
397 error[E0435]: attempt to use a non-constant value in a constant
398 --> $DIR/parse-error.rs:55:31
400 LL | let mut foo = 0;
401 | ---------- help: consider using `const` instead of `let`: `const foo`
403 LL | asm!("{a}", a = const foo, a = const bar);
404 | ^^^ non-constant value
406 error[E0435]: attempt to use a non-constant value in a constant
407 --> $DIR/parse-error.rs:55:46
409 LL | let mut bar = 0;
410 | ---------- help: consider using `const` instead of `let`: `const bar`
412 LL | asm!("{a}", a = const foo, a = const bar);
413 | ^^^ non-constant value
415 error[E0435]: attempt to use a non-constant value in a constant
416 --> $DIR/parse-error.rs:62:46
418 LL | let mut bar = 0;
419 | ---------- help: consider using `const` instead of `let`: `const bar`
421 LL | asm!("{a}", in("eax") 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:65:46
427 LL | let mut bar = 0;
428 | ---------- help: consider using `const` instead of `let`: `const bar`
430 LL | asm!("{a}", in("eax") 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:68:42
436 LL | let mut bar = 0;
437 | ---------- help: consider using `const` instead of `let`: `const bar`
439 LL | asm!("{1}", in("eax") foo, const bar);
440 | ^^^ non-constant value
442 error: aborting due to 63 previous errors
444 For more information about this error, try `rustc --explain E0435`.