re PR fortran/88980 (segfault on allocatable string member assignment)
commitda46c08e8b857d8ffc2332689e19c5277d25e7fd
authorPaul Thomas <pault@gcc.gnu.org>
Sat, 2 Feb 2019 09:16:44 +0000 (2 09:16 +0000)
committerPaul Thomas <pault@gcc.gnu.org>
Sat, 2 Feb 2019 09:16:44 +0000 (2 09:16 +0000)
treeee3c99e9e0766e3246de5eb54f4847736fb03e01
parent6bb45a6b52046f51193c34bbd026a13bf48b4b49
re PR fortran/88980 (segfault on allocatable string member assignment)

2019-02-02  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/88980
* trans-array.c (gfc_array_init_size): Add element_size to the
arguments.
(gfc_array_allocate): Remove the recalculation of the size of
the element and use element_size from the call to the above.
Unconditionally set the span field of the descriptor.

2019-02-02  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/88980
* gfortran.dg/realloc_on_assign_32.f90 : New test.

From-SVN: r268473
gcc/fortran/ChangeLog
gcc/fortran/trans-array.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/realloc_on_assign_32.f90 [new file with mode: 0644]