]> gcc.gnu.org Git - gcc.git/commit
Fortran: Fix assumed length chars and len inquiry [PR103716]
authorPaul Thomas <pault@gcc.gnu.org>
Tue, 23 May 2023 05:46:37 +0000 (06:46 +0100)
committerPaul Thomas <pault@gcc.gnu.org>
Thu, 28 Mar 2024 15:52:38 +0000 (15:52 +0000)
commit48d23749534ca96b3f0883579b44700a17e83d15
tree1ca96f9d6637f06b687fdfdcecfd1458316ee130
parent06454be4e4ce87a0665a1fa2681f8c2259f867d9
Fortran: Fix assumed length chars and len inquiry [PR103716]

2023-05-23  Paul Thomas  <pault@gcc.gnu.org>

gcc/fortran
PR fortran/103716
* resolve.cc (gfc_resolve_ref): Conversion of array_ref into an
element should be done for all characters without a len expr,
not just deferred lens, and for integer expressions.
* trans-expr.cc (conv_inquiry): For len and kind inquiry refs,
set the se string_length to NULL_TREE.

gcc/testsuite/
PR fortran/103716
* gfortran.dg/pr103716.f90 : New test.

(cherry picked from commit 842a432b02238361ecc601d301ac400a7f30f4fa)
gcc/fortran/resolve.cc
gcc/fortran/trans-expr.cc
gcc/testsuite/gfortran.dg/pr103716.f90 [new file with mode: 0644]
This page took 0.072113 seconds and 6 git commands to generate.