* valarith.c (value_binop): Handle BINOP_INTDIV

for unsigned and signed integers.
This commit is contained in:
Pierre Muller 2008-01-17 19:55:09 +00:00
parent 1de90795b9
commit ef80d18e09
2 changed files with 7 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2008-01-17 Pierre Muller <muller@ics.u-strasbg.fr>
* valarith.c (value_binop): Handle BINOP_INTDIV
for unsigned and signed integers.
2008-01-17 Ulrich Weigand <uweigand@de.ibm.com> 2008-01-17 Ulrich Weigand <uweigand@de.ibm.com>
* s390-tdep.c (s390_gdbarch_init): Set default long double * s390-tdep.c (s390_gdbarch_init): Set default long double

View File

@ -1033,6 +1033,7 @@ value_binop (struct value *arg1, struct value *arg2, enum exp_opcode op)
break; break;
case BINOP_DIV: case BINOP_DIV:
case BINOP_INTDIV:
v = v1 / v2; v = v1 / v2;
break; break;
@ -1152,6 +1153,7 @@ value_binop (struct value *arg1, struct value *arg2, enum exp_opcode op)
break; break;
case BINOP_DIV: case BINOP_DIV:
case BINOP_INTDIV:
if (v2 != 0) if (v2 != 0)
v = v1 / v2; v = v1 / v2;
else else