[Bug fortran/94578] Incorrect assignment of RESHAPE() result to a Fortran pointer
tkoenig at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Apr 16 14:21:08 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94578
--- Comment #5 from Thomas Koenig <tkoenig at gcc dot gnu.org> ---
Somewhat smaller test case:
program main
implicit none
type foo
integer :: x, y
end type foo
integer :: i
integer, dimension (2,2) :: array2d
integer, dimension(:), pointer :: array1d
type(foo), dimension(2*2), target :: solution
data array2d /1,2,3,4/
array1d => solution%x
print *,array2d
array1d = reshape (source=array2d, shape=shape(array1d))
print *,array1d
end program main
More information about the Gcc-bugs
mailing list