tidied up ChangeLogs (80 character line width), added reference
[deliverable/binutils-gdb.git] / gdb / std-regs.c
index 0bce7edd1f378649255949dfe18b18af2bd99fca..b568236966a05a51753d682f40ca7716ee875597 100644 (file)
@@ -1,6 +1,6 @@
 /* Builtin frame register, for GDB, the GNU debugger.
 
-   Copyright 2002 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2005 Free Software Foundation, Inc.
 
    Contributed by Red Hat.
 
@@ -18,8 +18,8 @@
 
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
+   Foundation, Inc., 51 Franklin Street, Fifth Floor,
+   Boston, MA 02110-1301, USA.  */
 
 #include "defs.h"
 #include "user-regs.h"
@@ -56,12 +56,12 @@ static struct value *
 value_of_builtin_frame_reg (struct frame_info *frame)
 {
   struct value *val;
-  char *buf;
+  gdb_byte *buf;
   build_builtin_type_frame_reg ();
   val = allocate_value (builtin_type_frame_reg);
   VALUE_LVAL (val) = not_lval;
-  buf = VALUE_CONTENTS_RAW (val);
-  memset (buf, TYPE_LENGTH (VALUE_TYPE (val)), 0);
+  buf = value_contents_raw (val);
+  memset (buf, 0, TYPE_LENGTH (value_type (val)));
   /* frame.base.  */
   if (frame != NULL)
     ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf,
@@ -85,9 +85,9 @@ value_of_builtin_frame_fp_reg (struct frame_info *frame)
   else
     {
       struct value *val = allocate_value (builtin_type_void_data_ptr);
-      char *buf = VALUE_CONTENTS_RAW (val);
+      gdb_byte *buf = value_contents_raw (val);
       if (frame == NULL)
-       memset (buf, TYPE_LENGTH (VALUE_TYPE (val)), 0);
+       memset (buf, 0, TYPE_LENGTH (value_type (val)));
       else
        ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf,
                            get_frame_base_address (frame));
@@ -103,9 +103,9 @@ value_of_builtin_frame_pc_reg (struct frame_info *frame)
   else
     {
       struct value *val = allocate_value (builtin_type_void_data_ptr);
-      char *buf = VALUE_CONTENTS_RAW (val);
+      gdb_byte *buf = value_contents_raw (val);
       if (frame == NULL)
-       memset (buf, TYPE_LENGTH (VALUE_TYPE (val)), 0);
+       memset (buf, 0, TYPE_LENGTH (value_type (val)));
       else
        ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf,
                            get_frame_pc (frame));
@@ -120,7 +120,7 @@ value_of_builtin_frame_sp_reg (struct frame_info *frame)
   if (SP_REGNUM >= 0)
     return value_of_register (SP_REGNUM, frame);
 #endif
-  error ("Standard register ``$sp'' is not available for this target");
+  error (_("Standard register ``$sp'' is not available for this target"));
 }
 
 static struct value *
@@ -130,7 +130,7 @@ value_of_builtin_frame_ps_reg (struct frame_info *frame)
   if (PS_REGNUM >= 0)
     return value_of_register (PS_REGNUM, frame);
 #endif
-  error ("Standard register ``$ps'' is not available for this target");
+  error (_("Standard register ``$ps'' is not available for this target"));
 }
 
 extern initialize_file_ftype _initialize_frame_reg; /* -Wmissing-prototypes */
@@ -142,7 +142,7 @@ _initialize_frame_reg (void)
      can't be initialized using _initialize*() or gdbarch.  Due mainly
      to non-multi-arch targets, GDB initializes things piece meal and,
      as a consequence can leave these types NULL.  */
-  REGISTER_GDBARCH_SWAP (builtin_type_frame_reg);
+  DEPRECATED_REGISTER_GDBARCH_SWAP (builtin_type_frame_reg);
 
   /* Frame based $fp, $pc, $sp and $ps.  These only come into play
      when the target does not define its own version of these
This page took 0.026993 seconds and 4 git commands to generate.