On Sat, May 04, 2013 at 05:13:51PM -0700, Jerry DeLisle wrote:
>  
>       CASE_SEPARATORS:        /* Not a repeat count.  */
>       case EOF:
> +     case '!':

      if (c == '!')
         gfc_warning("GNU Fortran extension: accepting a possibly "
                 "corrupted namelist");
>         goto done;
>  
>       default:
> @@ -890,6 +891,7 @@ read_integer (st_parameter_dt *dtp, int length)
>  
>       CASE_SEPARATORS:
>       case EOF:
> +     case '!':

     see above

>         goto done;
>  
>       default:
> @@ -1489,6 +1491,7 @@ read_real (st_parameter_dt *dtp, void * dest, int
>  
>       CASE_SEPARATORS:
>       case EOF:
> +     case '!':
>            if (c != '\n' && c != ',' && c != '\r' && c != ';')
>           unget_char (dtp, c);
>         goto done;
> @@ -1558,6 +1561,7 @@ read_real (st_parameter_dt *dtp, void * dest, int
>  
>       CASE_SEPARATORS:
>       case EOF:
> +     case '!':

     see above

>         goto done;
>  
>       case '.':
> @@ -1618,6 +1622,7 @@ read_real (st_parameter_dt *dtp, void * dest, int
>  
>       CASE_SEPARATORS:
>       case EOF:
> +     case '!':

    see above.

>         goto done;
>  
>       default:

I would prefer that gfortran issues an error.
Issuing a warning is acceptable.
Patch as is not OK IMHO.

PS: A vendor extension should be documented in the manual.

-- 
Steve

Reply via email to