aboutsummaryrefslogtreecommitdiff
path: root/gdb/value.c
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2005-01-27 21:00:59 +0000
committerAndrew Cagney <cagney@redhat.com>2005-01-27 21:00:59 +0000
commit79dd2d2463b44e50d224eb94edd40942dc467611 (patch)
treeb4c838d6bb9cdd1e8149491ff542720faedfa3c7 /gdb/value.c
parentc26b8e3b42c143d9262b52f43d6f204f305f0276 (diff)
downloadgdb-79dd2d2463b44e50d224eb94edd40942dc467611.zip
gdb-79dd2d2463b44e50d224eb94edd40942dc467611.tar.gz
gdb-79dd2d2463b44e50d224eb94edd40942dc467611.tar.bz2
2005-01-27 Andrew Cagney <cagney@gnu.org>
* gdbarch.sh (integer_to_address): Change buf parameter to a const bfd_byte, make pure-multi-arch. * gdbarch.h, gdbarch.c: Regenerate. * mips-tdep.c (mips_integer_to_address): Update. * value.c (value_as_address): Update.
Diffstat (limited to 'gdb/value.c')
-rw-r--r--gdb/value.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/gdb/value.c b/gdb/value.c
index 5afc5b4..3835a8a 100644
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -654,7 +654,7 @@ value_as_address (struct value *val)
take an address from a disassembly listing and give it to `x/i'.
This is certainly important.
- Adding an architecture method like INTEGER_TO_ADDRESS certainly
+ Adding an architecture method like integer_to_address() certainly
makes it possible for GDB to "get it right" in all circumstances
--- the target has complete control over how things get done, so
people can Do The Right Thing for their target without breaking
@@ -664,8 +664,9 @@ value_as_address (struct value *val)
if (TYPE_CODE (value_type (val)) != TYPE_CODE_PTR
&& TYPE_CODE (value_type (val)) != TYPE_CODE_REF
- && INTEGER_TO_ADDRESS_P ())
- return INTEGER_TO_ADDRESS (value_type (val), VALUE_CONTENTS (val));
+ && gdbarch_integer_to_address_p (current_gdbarch))
+ return gdbarch_integer_to_address (current_gdbarch, value_type (val),
+ VALUE_CONTENTS (val));
return unpack_long (value_type (val), VALUE_CONTENTS (val));
#endif