]> git.ipfire.org Git - thirdparty/gcc.git/commit
re PR fortran/47523 (Concatenation with deferred length character with lhs variable)
authorPaul Thomas <pault@gcc.gnu.org>
Sun, 30 Jan 2011 17:50:01 +0000 (17:50 +0000)
committerPaul Thomas <pault@gcc.gnu.org>
Sun, 30 Jan 2011 17:50:01 +0000 (17:50 +0000)
commitdafdf26963a622e074aeeeab399fbe33521d1baa
treeb8da97f66b986afd0a1f0f8d4f158a5b4dbd22d2
parent7be03a0ef9150f728b5710c0b9ca0962c137a4fc
re PR fortran/47523 (Concatenation with deferred length character with lhs variable)

2011-01-30  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/47523
* trans-expr.c (gfc_trans_assignment_1): If the rhs is an op
expr and is assigned to a deferred character length scalar,
make sure that the function is called before reallocation,
so that the length is available. Include procedure pointer
and procedure pointer component rhs as well.

2011-01-30  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/47523
* trans-expr.c (gfc_trans_assignment_1): If the rhs is an op
expr and is assigned to a deferred character length scalar,
make sure that the function is called before reallocation,
so that the length is available. Include procedure pointer
and procedure pointer component rhs as well.

PR fortran/45170
PR fortran/35810
PR fortran/47350
* gfortran.dg/allocatable_function_5.f90: New test not added by
mistake on 2011-01-28.

From-SVN: r169413
gcc/fortran/ChangeLog
gcc/fortran/trans-expr.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/allocatable_function_5.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/realloc_on_assign_5.f03 [new file with mode: 0644]