X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/6e30ede87a1c39c53842a6a747ecd9f7484d92a5..7287be84f10886ea3c38ac86da1d6642822b671e:/lib/bitset_stats.c diff --git a/lib/bitset_stats.c b/lib/bitset_stats.c index f67b0692..bde9b988 100644 --- a/lib/bitset_stats.c +++ b/lib/bitset_stats.c @@ -1,7 +1,6 @@ /* Bitset statistics. - Copyright (C) 2002, 2003, 2004, 2005, 2006, 2009, 2010 Free - Software Foundation, Inc. + Copyright (C) 2002-2006, 2009-2012 Free Software Foundation, Inc. Contributed by Michael Hayes (m.hayes@elec.canterbury.ac.nz). @@ -254,15 +253,15 @@ bitset_stats_read (const char *file_name) if (file) { if (fread (&bitset_stats_info_data, sizeof (bitset_stats_info_data), - 1, file) != 1) - { - if (ferror (file)) - perror (_("Could not read stats file.")); - else - fprintf (stderr, _("Bad stats file size.\n")); - } + 1, file) != 1) + { + if (ferror (file)) + perror (_("cannot read stats file")); + else + fprintf (stderr, _("bad stats file size\n")); + } if (fclose (file) != 0) - perror (_("Could not read stats file.")); + perror (_("cannot read stats file")); } bitset_stats_info_data.runs++; } @@ -284,13 +283,13 @@ bitset_stats_write (const char *file_name) if (file) { if (fwrite (&bitset_stats_info_data, sizeof (bitset_stats_info_data), - 1, file) != 1) - perror (_("Could not write stats file.")); + 1, file) != 1) + perror (_("cannot write stats file")); if (fclose (file) != 0) - perror (_("Could not write stats file.")); + perror (_("cannot write stats file")); } else - perror (_("Could not open stats file for writing.")); + perror (_("cannot open stats file for writing")); } @@ -577,11 +576,9 @@ bitset_stats_list (bitset bset, bitset_bindex *list, bitset_bindex tmp; bitset_bindex size; bitset_bindex i; - enum bitset_type type; count = BITSET_LIST_ (bset->s.bset, list, num, next); - type = BITSET_TYPE_ (bset->s.bset); BITSET_STATS_LISTS_INC (bset->s.bset); /* Log histogram of number of set bits. */