diff options
author | Simon Marchi <simon.marchi@efficios.com> | 2020-09-14 11:07:57 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@efficios.com> | 2020-09-14 11:07:57 -0400 |
commit | c6d940a9569deb4a89a5628caa78b1ccfcfd2bdf (patch) | |
tree | c5d25c2c2cd369f74ed393926638302e9da95c02 /gdb/valops.c | |
parent | 653223d3561b5976d12ade101113af9d08348b8c (diff) | |
download | gdb-c6d940a9569deb4a89a5628caa78b1ccfcfd2bdf.zip gdb-c6d940a9569deb4a89a5628caa78b1ccfcfd2bdf.tar.gz gdb-c6d940a9569deb4a89a5628caa78b1ccfcfd2bdf.tar.bz2 |
gdb: remove TYPE_UNSIGNED
gdb/ChangeLog:
* gdbtypes.h (TYPE_UNSIGNED): Remove, replace all uses with
type::is_unsigned.
Change-Id: I84f76f5cd44ff7294e421d317376a9e476bc8666
Diffstat (limited to 'gdb/valops.c')
-rw-r--r-- | gdb/valops.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/valops.c b/gdb/valops.c index 0eb2b09..60f6041 100644 --- a/gdb/valops.c +++ b/gdb/valops.c @@ -462,7 +462,7 @@ value_cast (struct type *type, struct value *arg2) } /* The only option left is an integral type. */ - if (TYPE_UNSIGNED (type2)) + if (type2->is_unsigned ()) return value_from_ulongest (to_type, value_as_long (arg2)); else return value_from_longest (to_type, value_as_long (arg2)); @@ -1230,7 +1230,7 @@ value_assign (struct value *toval, struct value *fromval) LONGEST valmask = (((ULONGEST) 1) << value_bitsize (toval)) - 1; fieldval &= valmask; - if (!TYPE_UNSIGNED (type) + if (!type->is_unsigned () && (fieldval & (valmask ^ (valmask >> 1)))) fieldval |= ~valmask; |