1 /* Wide string literals should not be allowed in asm. */
2 /* Origin: Joseph Myers <joseph@codesourcery.com> */
3 /* { dg-do compile } */
4 /* { dg-options "" } */
6 int foo
asm (L
"bar"); /* { dg-error "error: wide string literal in 'asm'" } */
8 asm (L
"foo"); /* { dg-error "error: wide string literal in 'asm'" } */
14 asm (L
"foo"); /* { dg-error "error: wide string literal in 'asm'" } */
16 L
"=g" (x
)); /* { dg-error "error: wide string literal in 'asm'" } */
18 L
"=g" (x
)); /* { dg-error "error: wide string literal in 'asm'" } */
19 asm ("foo" : [x
] "=g" (x
),
20 L
"=g" (x
)); /* { dg-error "error: wide string literal in 'asm'" } */
22 L
"g" (x
)); /* { dg-error "error: wide string literal in 'asm'" } */
24 L
"memory"); /* { dg-error "error: wide string literal in 'asm'" } */
25 asm ("foo" : : : "memory",
26 L
"memory"); /* { dg-error "error: wide string literal in 'asm'" } */
29 /* Extra errors from the substitution of "" for wide strings: */
30 /* { dg-error "output" "output" { target *-*-* } 16 } */
31 /* { dg-error "output" "output" { target *-*-* } 18 } */
32 /* { dg-error "output" "output" { target *-*-* } 20 } */
33 /* { dg-warning "match" "match" { target *-*-* } 21 } */
34 /* { dg-error "register" "register" { target *-*-* } 23 } */
35 /* { dg-error "register" "register" { target *-*-* } 25 } */