diff options
author | Paul Thomas <pault@gcc.gnu.org> | 2025-01-11 08:23:48 +0000 |
---|---|---|
committer | Paul Thomas <pault@gcc.gnu.org> | 2025-01-11 08:23:48 +0000 |
commit | d64ca15351029164bac30b49fb3c4f9723e755de (patch) | |
tree | c21dac1b0ebce75755c5456451df1c7f23b57e74 /gcc/fortran/gfortran.h | |
parent | 664bd76a23def2d458bb3c531486b4c220f29c11 (diff) | |
download | gcc-d64ca15351029164bac30b49fb3c4f9723e755de.zip gcc-d64ca15351029164bac30b49fb3c4f9723e755de.tar.gz gcc-d64ca15351029164bac30b49fb3c4f9723e755de.tar.bz2 |
Fortran: Fix error recovery for bad component arrayspecs [PR108434]
2025-01-11 Paul Thomas <pault@gcc.gnu.org>
gcc/fortran/
PR fortran/108434
* class.cc (generate_finalization_wrapper): To avoid memory
leaks from callocs, return immediately if the derived type
error flag is set.
* decl.cc (build_struct): If the declaration of a derived type
or class component does not have a deferred arrayspec, correct,
set the error flag of the derived type and emit an immediate
error.
gcc/testsuite/
PR fortran/108434
* gfortran.dg/pr108434.f90 : Add tests from comment 1.
Diffstat (limited to 'gcc/fortran/gfortran.h')
0 files changed, 0 insertions, 0 deletions