OSDN Git Service

2010-04-28 Manuel López-Ibáñez <manu@gcc.gnu.org>
[pf3gnuchains/gcc-fork.git] / gcc / genmodes.c
index 0a2e6f3..2aa559f 100644 (file)
@@ -6,7 +6,7 @@ This file is part of GCC.
 
 GCC is free software; you can redistribute it and/or modify it under
 the terms of the GNU General Public License as published by the Free
-Software Foundation; either version 2, or (at your option) any later
+Software Foundation; either version 3, or (at your option) any later
 version.
 
 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
@@ -15,9 +15,8 @@ FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 for more details.
 
 You should have received a copy of the GNU General Public License
-along with GCC; see the file COPYING.  If not, write to the Free
-Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301, USA.  */
+along with GCC; see the file COPYING3.  If not see
+<http://www.gnu.org/licenses/>.  */
 
 #include "bconfig.h"
 #include "system.h"
@@ -180,7 +179,7 @@ new_mode (enum mode_class cl, const char *name,
   n_modes[cl]++;
 
   *htab_find_slot (modes_by_name, m, INSERT) = m;
-  
+
   return m;
 }
 
@@ -231,7 +230,7 @@ new_adjust (const char *name,
             mode_class_names[required_class_to] + 5);
       return;
     }
-  
+
   for (a = *category; a; a = a->next)
     if (a->mode == mode)
       {
@@ -740,8 +739,8 @@ create_modes (void)
 static int
 cmp_modes (const void *a, const void *b)
 {
-  struct mode_data *m = *(struct mode_data **)a;
-  struct mode_data *n = *(struct mode_data **)b;
+  const struct mode_data *const m = *(const struct mode_data *const*)a;
+  const struct mode_data *const n = *(const struct mode_data *const*)b;
 
   if (m->bytesize > n->bytesize)
     return 1;
@@ -1148,7 +1147,7 @@ emit_class_narrowest_mode (void)
                         ? modes[c]->next->name
                         : void_mode->name))
                   : void_mode->name);
-  
+
   print_closer ();
 }
 
@@ -1296,7 +1295,7 @@ emit_mode_adjustments (void)
              a->file, a->line, a->adjustment);
       printf ("  mode_fbit[%smode] = s;\n", a->mode->name);
     }
-      
+
   /* Real mode formats don't have to propagate anywhere.  */
   for (a = adj_format; a; a = a->next)
     printf ("\n  /* %s:%d */\n  REAL_MODE_FORMAT (%smode) = %s;\n",
@@ -1398,7 +1397,7 @@ main (int argc, char **argv)
 
   if (have_error)
     return FATAL_EXIT_CODE;
-  
+
   calc_wider_mode ();
 
   if (gen_header)