diff options
Diffstat (limited to 'contrib/gcc/f/fini.c')
-rw-r--r-- | contrib/gcc/f/fini.c | 39 |
1 files changed, 21 insertions, 18 deletions
diff --git a/contrib/gcc/f/fini.c b/contrib/gcc/f/fini.c index 439ecca..1b7c981 100644 --- a/contrib/gcc/f/fini.c +++ b/contrib/gcc/f/fini.c @@ -1,6 +1,6 @@ /* fini.c Copyright (C) 1995 Free Software Foundation, Inc. - Contributed by James Craig Burley (burley@gnu.org). + Contributed by James Craig Burley. This file is part of GNU Fortran. @@ -19,9 +19,12 @@ along with GNU Fortran; see the file COPYING. If not, write to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ +#define USE_HCONFIG + #include "proj.h" #include "malloc.h" +#undef MAXNAMELEN #define MAXNAMELEN 100 typedef struct _name_ *name; @@ -59,7 +62,7 @@ static FILE *out; static char prefix[32]; static char postfix[32]; static char storage[32]; -static char *spaces[] +static const char *xspaces[] = { "", /* 0 */ @@ -633,7 +636,7 @@ testname (bool nested, int indent, name first, name last) int numhalf; assert (!nested || indent >= 2); - assert (((size_t) indent) + 4 < ARRAY_SIZE (spaces)); + assert (((size_t) indent) + 4 < ARRAY_SIZE (xspaces)); num = 0; numhalf = 0; @@ -651,15 +654,15 @@ testname (bool nested, int indent, name first, name last) "\ %s{\n\ ", - spaces[indent - 2]); + xspaces[indent - 2]); fprintf (out, "\ %sif ((c = ffesrc_strcmp_2c (ffe_case_match (), p, \"%s\", \"%s\", \"%s\")) == 0)\n\ %sreturn %s%s%s;\n\ ", - spaces[indent], nhalf->name_uc, nhalf->name_lc, nhalf->name_ic, - spaces[indent + 2], prefix, nhalf->kwname, postfix); + xspaces[indent], nhalf->name_uc, nhalf->name_lc, nhalf->name_ic, + xspaces[indent + 2], prefix, nhalf->kwname, postfix); if (num != 1) { @@ -667,14 +670,14 @@ testname (bool nested, int indent, name first, name last) "\ %selse if (c < 0)\n\ ", - spaces[indent]); + xspaces[indent]); if (numhalf == 0) fprintf (out, "\ %s;\n\ ", - spaces[indent + 2]); + xspaces[indent + 2]); else testname (TRUE, indent + 4, first, nhalf->previous); @@ -684,7 +687,7 @@ testname (bool nested, int indent, name first, name last) "\ %selse\n\ ", - spaces[indent]); + xspaces[indent]); testname (TRUE, indent + 4, nhalf->next, last); } @@ -695,7 +698,7 @@ testname (bool nested, int indent, name first, name last) "\ %s}\n\ ", - spaces[indent - 2]); + xspaces[indent - 2]); } void @@ -707,7 +710,7 @@ testnames (bool nested, int indent, int len, name first, name last) int numhalf; assert (!nested || indent >= 2); - assert (((size_t) indent) + 4 < ARRAY_SIZE (spaces)); + assert (((size_t) indent) + 4 < ARRAY_SIZE (xspaces)); num = 0; numhalf = 0; @@ -725,15 +728,15 @@ testnames (bool nested, int indent, int len, name first, name last) "\ %s{\n\ ", - spaces[indent - 2]); + xspaces[indent - 2]); fprintf (out, "\ %sif ((c = ffesrc_strncmp_2c (ffe_case_match (), p, \"%s\", \"%s\", \"%s\", %d)) == 0)\n\ %sreturn %s%s%s;\n\ ", - spaces[indent], nhalf->name_uc, nhalf->name_lc, nhalf->name_ic, - len, spaces[indent + 2], prefix, nhalf->kwname, postfix); + xspaces[indent], nhalf->name_uc, nhalf->name_lc, nhalf->name_ic, + len, xspaces[indent + 2], prefix, nhalf->kwname, postfix); if (num != 1) { @@ -741,14 +744,14 @@ testnames (bool nested, int indent, int len, name first, name last) "\ %selse if (c < 0)\n\ ", - spaces[indent]); + xspaces[indent]); if (numhalf == 0) fprintf (out, "\ %s;\n\ ", - spaces[indent + 2]); + xspaces[indent + 2]); else testnames (TRUE, indent + 4, len, first, nhalf->previous); @@ -758,7 +761,7 @@ testnames (bool nested, int indent, int len, name first, name last) "\ %selse\n\ ", - spaces[indent]); + xspaces[indent]); testnames (TRUE, indent + 4, len, nhalf->next, last); } @@ -769,5 +772,5 @@ testnames (bool nested, int indent, int len, name first, name last) "\ %s}\n\ ", - spaces[indent - 2]); + xspaces[indent - 2]); } |