Mercurial > hg > tinycc
changeset 388:25f4a44d713f
[project @ 2005-09-03 22:23:59 by bellard]
support for empty input register section in asm (Filip Navara)
author | bellard |
---|---|
date | Sat, 03 Sep 2005 22:23:59 +0000 |
parents | eaf3c68531af |
children | f308214b0cc6 |
files | tccasm.c |
diffstat | 1 files changed, 15 insertions(+), 13 deletions(-) [+] |
line wrap: on
line diff
--- a/tccasm.c Sat Sep 03 22:21:22 2005 +0000 +++ b/tccasm.c Sat Sep 03 22:23:59 2005 +0000 @@ -916,21 +916,23 @@ nb_outputs = nb_operands; if (tok == ':') { next(); - /* input args */ - parse_asm_operands(operands, &nb_operands, 0); - if (tok == ':') { - /* clobber list */ - /* XXX: handle registers */ - next(); - for(;;) { - if (tok != TOK_STR) - expect("string constant"); - asm_clobber(clobber_regs, tokc.cstr->data); + if (tok != ')') { + /* input args */ + parse_asm_operands(operands, &nb_operands, 0); + if (tok == ':') { + /* clobber list */ + /* XXX: handle registers */ next(); - if (tok == ',') { + for(;;) { + if (tok != TOK_STR) + expect("string constant"); + asm_clobber(clobber_regs, tokc.cstr->data); next(); - } else { - break; + if (tok == ',') { + next(); + } else { + break; + } } } }