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

            Bug ID: 95504
           Summary: ICE in transfer_array_component, at
                    fortran/trans-io.c:2167
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gs...@t-online.de
  Target Milestone: ---

Started with r8 before 20180525 :


$ cat z1.f90
program p
   type t(n)
      integer, len :: n
      integer, pointer :: a(:)
   end type
   type(t(3)) :: z
   print *, z
end


$ cat z2.f90
program p
   type t(n)
      integer, len :: n
      integer, allocatable :: a(:)
   end type
   type(t(3)) :: z
   print *, z
end


$ gfortran-11-20200531 -c z1.f90
z1.f90:7:0:

    7 |    print *, z
      |
internal compiler error: Segmentation fault
0xbc37bf crash_signal
        ../../gcc/toplev.c:328
0x75e576 transfer_array_component
        ../../gcc/fortran/trans-io.c:2167
0x75de47 transfer_expr
        ../../gcc/fortran/trans-io.c:2471
0x7616a0 gfc_trans_transfer(gfc_code*)
        ../../gcc/fortran/trans-io.c:2661
0x7017f7 trans_code
        ../../gcc/fortran/trans.c:2084
0x75f16e build_dt
        ../../gcc/fortran/trans-io.c:2026
0x7017d7 trans_code
        ../../gcc/fortran/trans.c:2056
0x72ad24 gfc_generate_function_code(gfc_namespace*)
        ../../gcc/fortran/trans-decl.c:6840
0x6b25e6 translate_all_program_units
        ../../gcc/fortran/parse.c:6306
0x6b25e6 gfc_parse_file()
        ../../gcc/fortran/parse.c:6545
0x6fdfff gfc_be_parse_file
        ../../gcc/fortran/f95-lang.c:210

Reply via email to