https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101399

            Bug ID: 101399
           Summary: Horizonal tab character not ignored on print statement
           Product: gcc
           Version: 9.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: urbanjost at comcast dot net
  Target Milestone: ---

Although gfortran defaults to allowing tab characters in source input as an
extension, a PRINT statement followed immediately by a horizontal tab character
fails

      print<\I>*,'tab not always ignored'
      end

where <\I> is a tab character reproduces the problem.

Showing source with a simple cat(1):

      $ cat x-x.f90
      print   *,'tab not always ignored'
      end$

Showing it actually has a tab character in it:

      $ cat -vet x-x.f90
      print^I*,'tab not always ignored'$
      end$

Get an error if try to compile:

      $ gfortran x-x.f90
      x-x.f90:1:0:

          1 | print *,'tab not always ignored'
            | 
      Error: Unclassifiable statement at (1)

remove tab from file and it compiles

      $ expand x-x.f90 >X-X.f90
      $ gfortran X-X.f90

Reply via email to