[Patch, Fortran] PR34899 - Support <tab><digit> as continuation line marker (fixed form)
Jerry DeLisle
jvdelisle@verizon.net
Tue Jan 22 12:27:00 GMT 2008
Tobias Burnus wrote:
> In standard fixed-form Fortran source code, a "normal" line begins with
> 6 spaces and a continuation line with 5 spaces plus some character such
> as '*' (there are some restrictions, see F95/F2003 standard).
>
> A very common vendor extension is to support <tab> as replacement for 6
> spaces, which also gfortran supports. However, how to create then a
> continuation line? Well, for g77, NAG f95, ifort, openf95, sunf95,
> pathscale, pgf95, Absoft the answer is: <tab><digit> where digit is not
> zero.
>
> The attached patch now does the following: It replaces '\t' by 6 spaces
> (before it was 7) and if the the tab is followed by a non-zero digit, it
> places it at position 6.
>
>
> Build and regression tested on x86-64-linux.
> OK for the trunk?
>
> Tobias
>
>
> PS: The patch was motivated to get to build
> http://www.chara.gsu.edu/~gudehus/fits_library_package.html. However,
> due to other problems it still won't build. gfortran stops first for
> integer_var = .true. (unless -std=legacy) and then for "real_var = ' '".
> Replacing them by transfer it stops at the same line as ifort.
The patch is OK. See my rant posted with the PR. Lets not make gfortran a
catch all compiler. The application you are wanting here really needs to be
fixed and done right. Neither gfortran or ifort should be expecte to compile crap.
Jerry
More information about the Fortran
mailing list