[Bug fortran/23924] New: No initialization of derived type pointers/allocatables when allocated
erik dot edelmann at iki dot fi
gcc-bugzilla@gcc.gnu.org
Fri Sep 16 21:46:00 GMT 2005
$ cat erik.f90
program test
type t
real :: a = 3.1
end type t
type(t), pointer :: p
type(t), allocatable :: q(:)
allocate(p)
print *, p%a
allocate(q(1))
print *, q(1)%a
end program test
$ gfortran erik.f90
$ a.out
0.000000
0.000000
The output I had expected is
3.100000
3.100000
given by ifort 8.1
--
Summary: No initialization of derived type pointers/allocatables
when allocated
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: erik dot edelmann at iki dot fi
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23924
More information about the Gcc-bugs
mailing list