diff options
author | Andrew Cagney <cagney@redhat.com> | 2005-02-08 04:57:03 +0000 |
---|---|---|
committer | Andrew Cagney <cagney@redhat.com> | 2005-02-08 04:57:03 +0000 |
commit | ff70e401d729f815254730bb640ad82889a70d9d (patch) | |
tree | 71ce3678bcb0a10d1fd641534b961fe90cb9c80e /gdb/ada-lang.c | |
parent | 4515748a5c590cfdb52237c652ad34e8bb59df61 (diff) | |
download | gdb-ff70e401d729f815254730bb640ad82889a70d9d.tar.gz |
2005-02-07 Andrew Cagney <cagney@gnu.org>
* value.c (set_value_bitpos, set_value_bitsize): Define.
* value.h (set_value_bitpos, set_value_bitsize): Declare.
* ada-lang.c, valarith.c: Update.
Diffstat (limited to 'gdb/ada-lang.c')
-rw-r--r-- | gdb/ada-lang.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index b3bed523033..b2fb2a671c2 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -448,8 +448,8 @@ coerce_unspec_val_to_type (struct value *val, struct type *type) result = allocate_value (type); VALUE_LVAL (result) = VALUE_LVAL (val); - result->bitsize = value_bitsize (val); - result->bitpos = value_bitpos (val); + set_value_bitsize (result, value_bitsize (val)); + set_value_bitpos (result, value_bitpos (val)); VALUE_ADDRESS (result) = VALUE_ADDRESS (val) + value_offset (val); if (value_lazy (val) || TYPE_LENGTH (type) > TYPE_LENGTH (value_type (val))) @@ -1830,16 +1830,16 @@ ada_value_primitive_packed_val (struct value *obj, const bfd_byte *valaddr, if (VALUE_LVAL (obj) == lval_internalvar) VALUE_LVAL (v) = lval_internalvar_component; VALUE_ADDRESS (v) = VALUE_ADDRESS (obj) + value_offset (obj) + offset; - v->bitpos = bit_offset + value_bitpos (obj); - v->bitsize = bit_size; + set_value_bitpos (v, bit_offset + value_bitpos (obj)); + set_value_bitsize (v, bit_size); if (value_bitpos (v) >= HOST_CHAR_BIT) { VALUE_ADDRESS (v) += 1; - v->bitpos -= HOST_CHAR_BIT; + set_value_bitpos (v, value_bitpos (v) - HOST_CHAR_BIT); } } else - v->bitsize = bit_size; + set_value_bitsize (v, bit_size); unpacked = (unsigned char *) value_contents (v); srcBitsLeft = bit_size; |