]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fortran: array subreferences and components of derived types [PR119986]
authorHarald Anlauf <anlauf@gmx.de>
Sat, 3 May 2025 18:35:57 +0000 (20:35 +0200)
committerHarald Anlauf <anlauf@gmx.de>
Mon, 12 May 2025 19:46:59 +0000 (21:46 +0200)
commit4a0e88c0c329ee69b13cdf2784c0c88edbca1f9e
tree6015654c3cf760da20cade5ad8dd1afab7947ed1
parent51ffec744b513a71fe84373fb87a3c0125b7fffd
Fortran: array subreferences and components of derived types [PR119986]

PR fortran/119986

gcc/fortran/ChangeLog:

* expr.cc (is_subref_array): When searching for array references,
do not terminate early so that inquiry references to complex
components work.
* primary.cc (gfc_variable_attr): A substring reference can refer
to either a scalar or array character variable.  Adjust search
accordingly.

gcc/testsuite/ChangeLog:

* gfortran.dg/actual_array_subref.f90: New test.

(cherry picked from commit fceb6022798b587c9111d0241aaff72602dcd626)
gcc/fortran/expr.cc
gcc/fortran/primary.cc
gcc/testsuite/gfortran.dg/actual_array_subref.f90 [new file with mode: 0644]