On Thu, 2007-10-11 at 12:16 -0400, Daniel Jacobowitz wrote: > On Thu, Sep 20, 2007 at 06:54:13PM -0300, Thiago Jung Bauermann wrote: > > + putithere->typed_val_decfloat.type = > > + builtin_type (current_gdbarch)->builtin_decfloat; > > Equals sign on next line please. Done. > > @@ -1376,6 +1376,20 @@ value_neg (struct value *arg1) > > > > type = check_typedef (value_type (arg1)); > > > > + if (TYPE_CODE (type) == TYPE_CODE_DECFLOAT) > > + { > > + struct value *val = allocate_value (result_type); > > + int len = TYPE_LENGTH (type); > > + gdb_byte *decbytes = (gdb_byte *) value_contents (arg1); > > + > > + if (gdbarch_byte_order (current_gdbarch) == BFD_ENDIAN_LITTLE) > > + decbytes[len-1] = decbytes[len - 1] | 0x80; > > + else > > + decbytes[0] = decbytes[0] | 0x80; > > + memcpy (value_contents_raw (val), decbytes, 16); > > + return val; > > + } > > + > > The reason we allocate a new value is to leave the existing value > unchanged, so you shouldn't modify the contents of arg1. The casts > are probably there because otherwise GCC complained you were removing > a const. Don't do that :-) Oops, that was indeed naughty. What about the version in this patch? > > +#include "dfp.h" > > If you add an #include, update Makefile.in. Oops, forgot about this dependency. Updated first patch in series to add $(dfp_h) dependency to c-exp.o target. -- []'s Thiago Jung Bauermann Software Engineer IBM Linux Technology Center