mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-24 10:35:12 +08:00
* expr.c (operand, operator): Don't reject '++' and '--'.
This commit is contained in:
parent
bc286f95ec
commit
1181c20ef4
@ -1,3 +1,7 @@
|
|||||||
|
2004-05-23 Alan Modra <amodra@bigpond.net.au>
|
||||||
|
|
||||||
|
* expr.c (operand, operator): Don't reject '++' and '--'.
|
||||||
|
|
||||||
2004-05-20 Richard Sandiford <rsandifo@redhat.com>
|
2004-05-20 Richard Sandiford <rsandifo@redhat.com>
|
||||||
|
|
||||||
* config/tc-mips.c (append_insn): Use ISA-encoded addresses in MIPS16
|
* config/tc-mips.c (append_insn): Use ISA-encoded addresses in MIPS16
|
||||||
|
15
gas/expr.c
15
gas/expr.c
@ -1021,8 +1021,9 @@ operand (expressionS *expressionP)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case '+':
|
case '+':
|
||||||
/* Do not accept ++e as +(+e) */
|
/* Do not accept ++e as +(+e).
|
||||||
if (*input_line_pointer == '+')
|
Disabled, since the preprocessor removes whitespace. */
|
||||||
|
if (0 && *input_line_pointer == '+')
|
||||||
goto target_op;
|
goto target_op;
|
||||||
(void) operand (expressionP);
|
(void) operand (expressionP);
|
||||||
break;
|
break;
|
||||||
@ -1041,8 +1042,9 @@ operand (expressionS *expressionP)
|
|||||||
case '!':
|
case '!':
|
||||||
case '-':
|
case '-':
|
||||||
{
|
{
|
||||||
/* Do not accept --e as -(-e) */
|
/* Do not accept --e as -(-e)
|
||||||
if (c == '-' && *input_line_pointer == '-')
|
Disabled, since the preprocessor removes whitespace. */
|
||||||
|
if (0 && c == '-' && *input_line_pointer == '-')
|
||||||
goto target_op;
|
goto target_op;
|
||||||
|
|
||||||
operand (expressionP);
|
operand (expressionP);
|
||||||
@ -1551,8 +1553,9 @@ operator (int *num_chars)
|
|||||||
|
|
||||||
case '+':
|
case '+':
|
||||||
case '-':
|
case '-':
|
||||||
/* Do not allow a++b and a--b to be a + (+b) and a - (-b) */
|
/* Do not allow a++b and a--b to be a + (+b) and a - (-b)
|
||||||
if (input_line_pointer[1] != c)
|
Disabled, since the preprocessor removes whitespace. */
|
||||||
|
if (1 || input_line_pointer[1] != c)
|
||||||
return op_encoding[c];
|
return op_encoding[c];
|
||||||
return O_illegal;
|
return O_illegal;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user