Hi, Attached proposed patch would close pr 21302 for me.
Is reusing -ffixed-line-length instead of introducing a new -fline-length ok? If it isn't, should -ffixed-line-length be renamed to -fline-length and -ffixed-line-length be an alias for the new -fline-length? thank you, Bernhard
Index: gcc/fortran/scanner.c =================================================================== RCS file: /cvsroot/gcc/gcc/gcc/fortran/scanner.c,v retrieving revision 1.22 diff -u -r1.22 scanner.c --- gcc/fortran/scanner.c 14 Jul 2005 07:14:37 -0000 1.22 +++ gcc/fortran/scanner.c 4 Aug 2005 17:58:42 -0000 @@ -680,7 +680,7 @@ In fixed mode, we expand a tab that occurs within the statement label region to expand to spaces that leave the next character in the source region. - load_line returns wether the line was truncated. */ + load_line returns whether the line was truncated. */ static int load_line (FILE * input, char **pbuf, int *pbuflen) @@ -690,9 +690,12 @@ char *buffer; /* Determine the maximum allowed line length. */ - if (gfc_current_form == FORM_FREE) - maxlen = GFC_MAX_LINE; - else + if (gfc_current_form == FORM_FREE) { + if (gfc_option.fixed_line_length == 72) /* default */ + maxlen = GFC_MAX_LINE; + else + maxlen = gfc_option.fixed_line_length; + } else maxlen = gfc_option.fixed_line_length; if (*pbuf == NULL)