This is the mail archive of the gcc-cvs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

r228339 - in /branches/gcc-5-branch/gcc: fortra...


Author: mikael
Date: Thu Oct  1 14:01:37 2015
New Revision: 228339

URL: https://gcc.gnu.org/viewcvs?rev=228339&root=gcc&view=rev
Log:
Fix missing deep copy when assigning a DT constructor to an array

This adds the missing deep copy when assiging a constructor of a derived
type with allocatable components to an array.

The check for constantness is removed so that the deep_copy argument passed
to gfc_trans_scalar_assign is set to true.

	PR fortran/67721
gcc/fortran/
	* trans-expr.c (gfc_trans_assignment_1): Remove the non-constantness
	condition guarding deep copy.
gcc/testsuite/
	* gfortran.dg/alloc_comp_deep_copy_3.f03: New.


Added:
    branches/gcc-5-branch/gcc/testsuite/gfortran.dg/alloc_comp_deep_copy_3.f03
Modified:
    branches/gcc-5-branch/gcc/fortran/ChangeLog
    branches/gcc-5-branch/gcc/fortran/trans-expr.c
    branches/gcc-5-branch/gcc/testsuite/ChangeLog


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]