diff options
author | Andrew Cagney <cagney@redhat.com> | 2003-05-03 00:26:34 +0000 |
---|---|---|
committer | Andrew Cagney <cagney@redhat.com> | 2003-05-03 00:26:34 +0000 |
commit | 82de1e5bfbe5e536e9b240fd4a9eefbe52bdeedb (patch) | |
tree | b5dd8db7bed5f662474756221b93a1e550db5d4a /gdb/std-regs.c | |
parent | 75d2dc161aa9bc05546269de4589313478d4412b (diff) | |
download | gdb-82de1e5bfbe5e536e9b240fd4a9eefbe52bdeedb.zip gdb-82de1e5bfbe5e536e9b240fd4a9eefbe52bdeedb.tar.gz gdb-82de1e5bfbe5e536e9b240fd4a9eefbe52bdeedb.tar.bz2 |
2003-05-02 Andrew Cagney <cagney@redhat.com>
* std-regs.c (value_of_builtin_frame_pc_reg): Delete #ifdef
PC_REGNUM, re-indent.
* stack.c (frame_info): Use "pc" for the name of get_frame_pc when
PC_REGNUM isn't set.
Diffstat (limited to 'gdb/std-regs.c')
-rw-r--r-- | gdb/std-regs.c | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/gdb/std-regs.c b/gdb/std-regs.c index 9f6f9ac..93d5102 100644 --- a/gdb/std-regs.c +++ b/gdb/std-regs.c @@ -98,20 +98,19 @@ value_of_builtin_frame_fp_reg (struct frame_info *frame) static struct value * value_of_builtin_frame_pc_reg (struct frame_info *frame) { -#ifdef PC_REGNUM if (PC_REGNUM >= 0) return value_of_register (PC_REGNUM, frame); -#endif - { - struct value *val = allocate_value (builtin_type_void_data_ptr); - char *buf = VALUE_CONTENTS_RAW (val); - if (frame == NULL) - memset (buf, TYPE_LENGTH (VALUE_TYPE (val)), 0); - else - ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf, - get_frame_pc (frame)); - return val; - } + else + { + struct value *val = allocate_value (builtin_type_void_data_ptr); + char *buf = VALUE_CONTENTS_RAW (val); + if (frame == NULL) + memset (buf, TYPE_LENGTH (VALUE_TYPE (val)), 0); + else + ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf, + get_frame_pc (frame)); + return val; + } } static struct value * |