https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78641
--- Comment #9 from Paul Thomas <pault at gcc dot gnu.org> --- Author: pault Date: Mon Nov 6 11:50:53 2017 New Revision: 254449 URL: https://gcc.gnu.org/viewcvs?rev=254449&root=gcc&view=rev Log: 2017-11-06 Paul Thomas <pa...@gcc.gnu.org> Backported from trunk PR fortran/78641 * resolve.c (resolve_ordinary_assign): Do not add the _data component for class valued array constructors being assigned to derived type arrays. * trans-array.c (gfc_trans_array_ctor_element): Take the _data of class valued elements for assignment to derived type arrays. 2017-11-06 Paul Thomas <pa...@gcc.gnu.org> Backported from trunk PR fortran/78641 * gfortran.dg/class_66.f90: New test. Added: branches/gcc-6-branch/gcc/testsuite/gfortran.dg/class_66.f90 Modified: branches/gcc-6-branch/gcc/fortran/ChangeLog branches/gcc-6-branch/gcc/fortran/resolve.c branches/gcc-6-branch/gcc/fortran/trans-array.c branches/gcc-6-branch/gcc/testsuite/ChangeLog