re PR fortran/82923 (Automatic allocation of deferred length character using function...
authorPaul Thomas <pault@gcc.gnu.org>
Sun, 20 May 2018 09:59:54 +0000 (09:59 +0000)
committerPaul Thomas <pault@gcc.gnu.org>
Sun, 20 May 2018 09:59:54 +0000 (09:59 +0000)
commit7c71e79664fbc04c3eb1d8b0307b33e502488664
tree37d3d79d63b181d1efcb204fd84191266809ecda
parent69e7672a3bc8b1b40b92277437947f2778c51b96
re PR fortran/82923 (Automatic allocation of deferred length character using function result)

2018-05-19  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/82923
PR fortran/66694
PR fortran/82617
* trans-array.c (gfc_alloc_allocatable_for_assignment): Set the
charlen backend_decl of the rhs expr to ss->info->string_length
so that the value in the current scope is used.

2018-05-19  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/82923
* gfortran.dg/allocate_assumed_charlen_4.f90: New test. Note
that the patch fixes PR66694 & PR82617, although the testcases
are not explicitly included.

From-SVN: r260413
gcc/fortran/ChangeLog
gcc/fortran/match.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/select_type_42.f90 [new file with mode: 0644]