[Bug fortran/14956] [gfortran] does not support # of line longer than 80 character

bdavis9659 at comcast dot net gcc-bugzilla@gcc.gnu.org
Thu Apr 15 17:23:00 GMT 2004


------- Additional Comments From bdavis9659 at comcast dot net  2004-04-15 16:43 -------
I think this is just the difference between fixed and free source format:

$ cat xx.f
      subroutine initialize(mode,number_of_output,nstartnm,
     #     startnm,startch)
      end
 
$ g77 -c xx.f
$ gfortran -c xx.f

when compiling a .f file, gfortran assumes fixed (F77) style source.

But when given, a .f90 file, it assumes free format, which detects the "#" as a
spurious character, not "something in column 6".

$ mv xx.f xx.f90
$ gfortran xx.f90
 In file xx.f90:1
 
      subroutine initialize(mode,number_of_output,nstartnm,
     1
Error: Unclassifiable statement at (1)
 In file xx.f90:2
 
     #     startnm,startch)
    1
Error: Unclassifiable statement at (1)


Which is fine.

I think this PR can be closed.  Works as it should.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pinskia at gcc dot gnu dot
                   |                            |org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14956



More information about the Gcc-bugs mailing list