This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: more than 10 operands in `asm'
- To: Jamie Lokier <egcs at tantalophile dot demon dot co dot uk>
- Subject: Re: more than 10 operands in `asm'
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Sat, 07 Nov 1998 11:52:08 -0700
- cc: David Edelsohn <dje at watson dot ibm dot com>, Kamil Iskra <kamil at dwd dot interkom dot pl>, egcs at cygnus dot com
- Reply-To: law at cygnus dot com
In message <19981107121802.A23552@comlab.ox.ac.uk>you write:
> Two more syntax possibilities:
>
> - Retain the old meaning of %10 when there are fewer than ten
> operands, but treat it as operand #10 when there are ten or more
> operands. This is nice because it's definitely backwards compatible.
>
> To avoid too many surprises, I'd make the rule: if there are fewer than
> 10 operands, %[0-9] is an operand and %[0-9][0-9]+ elicits a warning.
> If there are 10 or more operands, %[0-9]+ is an operand and all digits
> are consumed. A number out of range is an error.
>
> - Extend the syntax to %{[0-9]+} for multi-digit operands.
Ewwwww. It may be backwards compatible, but it's butt ugly.
Better to find any old style %digitdigit strings and fix them or define
a simple syntax without context rules.
jeff