[Bug fortran/68440] New: ICE on declaring class variable with wrong attribute

gerhard.steinmetz.fortran@t-online.de gcc-bugzilla@gcc.gnu.org
Thu Nov 19 17:45:00 GMT 2015


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

            Bug ID: 68440
           Summary: ICE on declaring class variable with wrong attribute
           Product: gcc
           Version: 5.2.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gerhard.steinmetz.fortran@t-online.de
  Target Milestone: ---

This wrong code (class not allocatable nor pointer) :

$ cat z1.f90
subroutine s
   type t
   end type
   class(t), parameter :: x = t()
   class(t), parameter :: y = x
end

$ gfortran -g -O0 -Wall -fcheck=all z1.f90
f951: internal compiler error: in check_alloc_comp_init, at fortran/expr.c:2209

---

$ cat z2.f90
subroutine s
   type t
   end type
   class(t), parameter :: x = t()
   class(t) :: y = x
end

$ gfortran -g -O0 -Wall -fcheck=all z2.f90
f951: internal compiler error: in check_alloc_comp_init, at fortran/expr.c:2209


More information about the Gcc-bugs mailing list