forked from Mirrors/tinycc
support for empty input register section in asm (Filip Navara)
parent
e9c64e3f47
commit
7b8e283980
28
tccasm.c
28
tccasm.c
|
@ -916,21 +916,23 @@ static void asm_instr(void)
|
||||||
nb_outputs = nb_operands;
|
nb_outputs = nb_operands;
|
||||||
if (tok == ':') {
|
if (tok == ':') {
|
||||||
next();
|
next();
|
||||||
/* input args */
|
if (tok != ')') {
|
||||||
parse_asm_operands(operands, &nb_operands, 0);
|
/* input args */
|
||||||
if (tok == ':') {
|
parse_asm_operands(operands, &nb_operands, 0);
|
||||||
/* clobber list */
|
if (tok == ':') {
|
||||||
/* XXX: handle registers */
|
/* clobber list */
|
||||||
next();
|
/* XXX: handle registers */
|
||||||
for(;;) {
|
|
||||||
if (tok != TOK_STR)
|
|
||||||
expect("string constant");
|
|
||||||
asm_clobber(clobber_regs, tokc.cstr->data);
|
|
||||||
next();
|
next();
|
||||||
if (tok == ',') {
|
for(;;) {
|
||||||
|
if (tok != TOK_STR)
|
||||||
|
expect("string constant");
|
||||||
|
asm_clobber(clobber_regs, tokc.cstr->data);
|
||||||
next();
|
next();
|
||||||
} else {
|
if (tok == ',') {
|
||||||
break;
|
next();
|
||||||
|
} else {
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue