Remove commented-out code in jv-lang.c
[binutils-gdb.git] / gdb / f-valprint.c
index 0a574042fcd63a0e440be62d0ff5bf8ad2337071..acd648758be569fb8183fb0b2c82070c8de6bb87 100644 (file)
@@ -1,7 +1,7 @@
 /* Support for printing Fortran values for GDB, the GNU debugger.
 
    Copyright (C) 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2003, 2005, 2006,
-   2007, 2008, 2009 Free Software Foundation, Inc.
+   2007, 2008, 2009, 2010 Free Software Foundation, Inc.
 
    Contributed by Motorola.  Adapted from the C definitions by Farooq Butt
    (fmbutt@engage.sps.mot.com), additionally worked over by Stan Shebs.
@@ -92,7 +92,6 @@ f77_get_dynamic_length_of_aggregate (struct type *type)
 {
   int upper_bound = -1;
   int lower_bound = 1;
-  int retcode;
 
   /* Recursively go all the way down into a possibly multi-dimensional
      F77 array and get the bounds.  For simple arrays, this is pretty
@@ -126,7 +125,7 @@ f77_create_arrayprint_offset_tbl (struct type *type, struct ui_file *stream)
   struct type *tmp_type;
   int eltlen;
   int ndimen = 1;
-  int upper, lower, retcode;
+  int upper, lower;
 
   tmp_type = type;
 
@@ -259,7 +258,7 @@ f_val_print (struct type *type, const gdb_byte *valaddr, int embedded_offset,
     case TYPE_CODE_STRING:
       f77_get_dynamic_length_of_aggregate (type);
       LA_PRINT_STRING (stream, builtin_type (gdbarch)->builtin_char,
-                      valaddr, TYPE_LENGTH (type), 0, options);
+                      valaddr, TYPE_LENGTH (type), NULL, 0, options);
       break;
 
     case TYPE_CODE_ARRAY:
@@ -312,6 +311,7 @@ f_val_print (struct type *type, const gdb_byte *valaddr, int embedded_offset,
        {
          CORE_ADDR addr
            = extract_typed_address (valaddr + embedded_offset, type);
+
          fprintf_filtered (stream, "@");
          fputs_filtered (paddress (gdbarch, addr), stream);
          if (options->deref_ref)
@@ -323,9 +323,10 @@ f_val_print (struct type *type, const gdb_byte *valaddr, int embedded_offset,
          if (TYPE_CODE (elttype) != TYPE_CODE_UNDEF)
            {
              struct value *deref_val =
-             value_at
-             (TYPE_TARGET_TYPE (type),
-              unpack_pointer (type, valaddr + embedded_offset));
+               value_at
+               (TYPE_TARGET_TYPE (type),
+                unpack_pointer (type, valaddr + embedded_offset));
+
              common_val_print (deref_val, stream, recurse,
                                options, current_language);
            }
@@ -353,6 +354,7 @@ f_val_print (struct type *type, const gdb_byte *valaddr, int embedded_offset,
       if (options->format || options->output_format)
        {
          struct value_print_options opts = *options;
+
          opts.format = (options->format ? options->format
                         : options->output_format);
          print_scalar_formatted (valaddr, type, &opts, 0, stream);
@@ -404,6 +406,7 @@ f_val_print (struct type *type, const gdb_byte *valaddr, int embedded_offset,
       if (options->format || options->output_format)
        {
          struct value_print_options opts = *options;
+
          opts.format = (options->format ? options->format
                         : options->output_format);
          print_scalar_formatted (valaddr, type, &opts, 0, stream);
@@ -452,6 +455,7 @@ f_val_print (struct type *type, const gdb_byte *valaddr, int embedded_offset,
       for (index = 0; index < TYPE_NFIELDS (type); index++)
         {
           int offset = TYPE_FIELD_BITPOS (type, index) / 8;
+
           f_val_print (TYPE_FIELD_TYPE (type, index), valaddr + offset,
                        embedded_offset, address, stream, recurse, options);
           if (index != TYPE_NFIELDS (type) - 1)
@@ -538,7 +542,7 @@ info_common_command (char *comname, int from_tty)
   else
     {
       struct minimal_symbol *msymbol =
-      lookup_minimal_symbol_by_pc (get_frame_pc (fi));
+       lookup_minimal_symbol_by_pc (get_frame_pc (fi));
 
       if (msymbol != NULL)
        funname = SYMBOL_LINKAGE_NAME (msymbol);
@@ -627,7 +631,7 @@ there_is_a_visible_common_named (char *comname)
   else
     {
       struct minimal_symbol *msymbol =
-      lookup_minimal_symbol_by_pc (fi->pc);
+       lookup_minimal_symbol_by_pc (fi->pc);
 
       if (msymbol != NULL)
        funname = SYMBOL_LINKAGE_NAME (msymbol);