------- Comment #19 from janus at gcc dot gnu dot org 2010-01-30 10:29 ------- (In reply to comment #17) > There is another problem left with the patch. I am not sure whether the > code is legal, but it gives an ICE for me: > > implicit none > type t > integer :: X = -999.0 ! Real initializer! > end type t > class(t), allocatable :: x > class(t), allocatable :: y(:) > allocate (t::x) > allocate (t::y(1)) ! ICE > end > > gfcbug103a.f90: In function MAIN__: > gfcbug103a.f90:8:0: internal compiler error: Segmentation fault
Yes, it is legal. And the ICE is kind of expected right now, since CLASS arrays are not really supported yet (cf. PR42539, PR41600, PR41951; the second one contains a similar ALLOCATE statement). Implementing CLASS array support requires an array descriptor update, so it is 4.6 stuff. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42888