]> gcc.gnu.org Git - gcc.git/commit
Fortran: Fix some problems with SELECT TYPE selectors [PR104625].
authorPaul Thomas <pault@gcc.gnu.org>
Fri, 27 Oct 2023 08:33:38 +0000 (09:33 +0100)
committerPaul Thomas <pault@gcc.gnu.org>
Fri, 27 Oct 2023 08:33:38 +0000 (09:33 +0100)
commitb038e202210eb3e982c2ec802438edd523b47a02
treea66f3d2ee1a26721e2eb24ba148abb84de1f231a
parenta5e69e94591ae282857d59e868ff6cea7306c802
Fortran: Fix some problems with SELECT TYPE selectors [PR104625].

2023-10-27  Paul Thomas  <pault@gcc.gnu.org>

gcc/fortran
PR fortran/104625
* expr.cc (gfc_check_vardef_context): Check that the target
does have a vector index before emitting the specific error.
* match.cc (copy_ts_from_selector_to_associate): Ensure that
class valued operator expressions set the selector rank and
use the rank to provide the associate variable with an
appropriate array spec.
* resolve.cc (resolve_operator): Reduce stacked parentheses to
a single pair.
(fixup_array_ref): Extract selector symbol from parentheses.

gcc/testsuite/
PR fortran/104625
* gfortran.dg/pr104625.f90: New test.
* gfortran.dg/associate_55.f90: Change error check.
gcc/fortran/expr.cc
gcc/fortran/match.cc
gcc/fortran/resolve.cc
gcc/testsuite/gfortran.dg/associate_55.f90
gcc/testsuite/gfortran.dg/pr104625.f90 [new file with mode: 0644]
This page took 0.076397 seconds and 5 git commands to generate.