[Patch, fortran] PR67740 - Wrong association status of allocatable character pointer in derived types
Paul Richard Thomas
paul.richard.thomas@gmail.com
Wed Oct 11 08:48:17 GMT 2023
Hi All,
The title line of the PR should have been changed a long time since. As
noted in comment 5, the original problem was fixed in 10.5.
This patch fixes the problem described in comments 4 and 6, where the
hidden string length component was not being set in pointer assignment of
character arrays.
The fix regtests. OK for trunk and 13-branch?
Thanks are due to Harald for bringing this to my attention.
Paul
Fortran: Set hidden string length for pointer components [PR67440]
2023-10-11 Paul Thomas <pault@gcc.gnu.org>
gcc/fortran
PR fortran/pr67740
* trans-expr.cc (gfc_trans_pointer_assignment): Set the hidden
string length component for pointer assignment to character
pointer components.
gcc/testsuite/
PR fortran/87477
* gfortran.dg/pr67740.f90: New test
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://gcc.gnu.org/pipermail/fortran/attachments/20231011/2bb91c62/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr67740.f90
Type: text/x-fortran
Size: 924 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/fortran/attachments/20231011/2bb91c62/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: submit.diff
Type: text/x-patch
Size: 1546 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/fortran/attachments/20231011/2bb91c62/attachment-0001.bin>
More information about the Fortran
mailing list