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

            Bug ID: 82049
           Summary: ICE with character(*),parameter array constructor
           Product: gcc
           Version: 6.3.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: john.harper at vuw dot ac.nz
  Target Milestone: ---

Internal compiler error presumably due to a character parameter array
constructor.

The program (6 lines):

program ice ! f2003
  implicit none
  character(*),parameter:: filename = 'ice', stdout = '*',&
       names(2) = [character(len(filename))::filename,stdout]
  print "(2A4)",adjustr(names)
end program ice

The compile-time result with gfortran 6.3.1:

cayley[~/Jfh] % gfortran -std=f2003 gfortranice7.f90
f951: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://bugs.archlinux.org/> for instructions.
cayley[~/Jfh]

Same bad result with -std=f2008. With 3 other compilers (g95,ifort,Sun), the 
program compiled and ran, printing 

 ice   *

Reply via email to